home *** CD-ROM | disk | FTP | other *** search
/ Night Owl 6 / Night Owl's Shareware - PDSI-006 - Night Owl Corp (1990).iso / 010a / hdts535a.zip / HDTEST.DOC < prev    next >
Text File  |  1991-10-20  |  157KB  |  2,662 lines

  1.           
  2.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  3.           
  4.           
  5.  
  6.  
  7.  
  8.  
  9.  
  10.  
  11.  
  12.  
  13.                           HDTEST - Hard Disk Test/Repair Utility                          ______________________________________
  14.  
  15.                            Copyright (1984-1991), P. R. Fletcher                           _____________________________________
  16.                                     All Rights Reserved                                    ___________________
  17.  
  18.  
  19.  
  20.                         Distributed by:
  21.  
  22.                                Computer Counselors, Inc.
  23.                                1515 West Montgomery Avenue
  24.                                Rosemont
  25.                                PA 19010
  26.  
  27.  
  28.  
  29.  
  30.  
  31.                                   _______
  32.                              ____|__     |               (r)
  33.                           --|       |    |-------------------
  34.                             |   ____|__  |  Association of
  35.                             |  |       |_|  Shareware
  36.                             |__|   o   |    Professionals
  37.                           -----|   |   |---------------------
  38.                                |___|___|    MEMBER
  39.  
  40.            
  41.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  42.           
  43.           
  44.                                      TABLE OF CONTENTS                                     _________________
  45.  
  46.  
  47.           User-Supported Software                                    1
  48.           Introduction                                               1
  49.           Getting Started - Installation                             5
  50.                           - Testing a Disk                           5
  51.           Hardware and Software Requirements                         7
  52.           Limitations and Restrictions                               9
  53.           Command Line Options - HDCHEK                             10
  54.                                - HDTEST                             13
  55.           What does HDTEST do?                                      16
  56.           Incremental Disk Testing                                  18
  57.           Using the On-Disk Pre-Boot                                18
  58.           Using the HD programs with SpeedStor and Disk Manager     21
  59.           Special considerations with SpeedStor                     22
  60.           Dealing with Bad Clusters                                 22
  61.           Running HDTEST from a .BAT file                           24
  62.           Bugs and Other Unpleasant Subjects                        25
  63.           Changes from Previous Versions                            25
  64.           Appendix A - Summary of Flag Settings                     31
  65.           Appendix B - A Hardware Tutorial                          33
  66.                      - Disk Error Reports                           36
  67.           Appendix C - Example Program Runs                         41
  68.           Registration Form                                         44
  69.            
  70.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  71.           
  72.           
  73.                                   USER-SUPPORTED SOFTWARE                                  _______________________
  74.  
  75.           Much of the software which is available for your computer has, in the
  76.           past, been produced and sold on the assumption that most computer
  77.           users are crooks who will take any available opportunity to cheat
  78.           software writers and vendors out of their rightful rewards. Such
  79.           software was copy-protected within an inch of its (and your
  80.           computer's) life and was priced at a level which still guaranteed its
  81.           producers a profit even if four or five illegal copies were made for
  82.           each one sold. Thankfully, prices of commercial software have (for the
  83.           most part) come down somewhat, and copy-protection is becoming much
  84.           less prevalent, but buying commercial software remains something of a
  85.           lottery - you often cannot be sure that the software does what you
  86.           want in the way you want it done until you have paid for it. User-
  87.           supported software (Shareware) is different. You may have got a copy
  88.           of this package free from a friend or a bulletin board or (for a
  89.           nominal fee) from a users' group or software library. In any case, you
  90.           have a perfectly legal working copy of the HDTEST package. You are
  91.           encouraged to make as many copies of the package as you like and to
  92.           distribute them to all your friends. If, after trying the program out,
  93.           you find that it is useful and want to continue to keep and use it,
  94.           you must register your copy by sending the registration fee ($35.00,
  95.           unless you are already a registered user of DIREDIT, in which case it
  96.           is $25.00) together with the completed registration form, to the
  97.           address on the form. Only your conscience can make you do this                                                        ____            
  98.           (although you are probably breaking the law if you don't), but bear in
  99.           mind that the distributors of "user-supported" software are making the
  100.           assumption that you are honest and willing to pay a reasonable price
  101.           for a useful program, many commercial software vendors, on the other
  102.           hand, would still apparently rather believe you are a crook. You can
  103.           decide who you would rather prove right. Registered users are entitled
  104.           to support, upgrades, and help with HDTEST-related problems (including
  105.           telephone support) for a year from the date of registration.
  106.  
  107.           This program is produced by a member of the Association of Shareware
  108.           Professionals (ASP).  ASP wants to make sure that the shareware
  109.           principle works for you. If you are unable to resolve a shareware-
  110.           related problem with an ASP member by contacting the member directly,
  111.           ASP may be able to help. The ASP Ombudsman can help you resolve a
  112.           dispute or problem with an ASP member, but does not provide technical
  113.           support for members' products. Please write to the ASP Ombudsman at
  114.           545 Grover Road, Muskegon, MI 49442-9427 or send a Compuserve message
  115.           via CompuServe Mail to ASP Ombudsman 70007,3536"
  116.  
  117.  
  118.                                        INTRODUCTION                                       ____________
  119.  
  120.           HDTEST was originally written to allow comprehensive Read/Write
  121.           testing of hard disks on IBM PCs, XTs, ATs, and "true" compatibles.
  122.           The V4.10 release removed many of the hardware restrictions imposed by
  123.           earlier (V2.xx and V3.xx) versions of the program and made it useful
  124.           for testing most MS-DOS-compatible storage devices currently in use on
  125.            
  126.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  127.           
  128.           
  129.           IBM-compatible computers, including removable (floppy and hard) disks
  130.           and logically partitioned hard disks. The V4.34 release included BIOS-
  131.           level support for DOS 3.3 (and above) "extended devices" and more
  132.           options for the handling of totally unreadable sectors. The V4.53
  133.           release added even more extensive support for IBM-incompatible
  134.           hardware and removed the requirement that ANSI.SYS be loaded to
  135.           support a proper screen display. Subsequent releases added full
  136.           support for the large (> 32Mb) devices allowed by DOS 4.0, the ability
  137.           to locate bad spots physically (by track, head, and sector) on the
  138.           disk, and some support for the use of .BAT files to run HDTEST on
  139.           multiple disks at one "sitting". The V5.20 release added INT 13 level
  140.           support for hard disks with more than 1024 heads which have been
  141.           partitioned by the SpeedStor or Disk Manager utilities, as well as
  142.           full support for proprietary Disk Manager and SpeedStor partitions
  143.           under DOS versions prior to 4.00 (or Compaq DOS 3.31). The V5.35
  144.           release included a number of changes and improvements, mainly aimed at
  145.           allowing the programs to be used on even bigger partitions, but also
  146.           including support for MS DOS 5.0 and (some) support for DR DOS 5.0.
  147.  
  148.           Although many programs, including IBM's diagnostics, allow "surface
  149.           scanning" and seek testing of hard disks, few that are available to
  150.           the average user test whether the whole disk can retain the data that
  151.           is or will be written to it. HDTEST's principal "claim to fame" is the
  152.           ability thoroughly to test the magnetic media in a device which
  153.           contains data while preserving the data (although data loss is                        _________________________                       
  154.           unavoidable if an area which is in use has become unreadable). HDTEST                                                              ____             
  155.           tests the disk much more thoroughly than programs such as DFixer,
  156.           Mace, and Norton's DT. Mace and DT, like many public domain "disk
  157.           test" programs, simply read every cluster on the disk and report on
  158.           any errors encountered.  DFixer does better, writing 4 test patterns
  159.           to every free cluster and checking that they can be read back
  160.           correctly, but it makes no attempt to test clusters that are already
  161.           in use - the very ones which contain your precious data! Disk
  162.           Technician (TM), a product which has come to market more recently,
  163.           is more closely comparable to HDTEST than any other disk testing
  164.           program that I know about. It is, however, much more expensive, is
  165.           (functionally, at least) copy-protected, and is not available as                                                          ___             
  166.           Shareware!
  167.  
  168.           In addition to its testing function, HDTEST has been reported to be
  169.           useful as an automatic disk repair utility for both hard and floppy
  170.           disks which have developed (especially) intermittent or persistent
  171.           read errors, preventing or impeding their normal use. Although HDTEST
  172.           cannot read the totally unreadable, it tries much harder that DOS does
  173.           and will almost always, in the course of its operation, allow you to
  174.           recover the entire readable portion(s) of a file with one or more                             ________                                      
  175.           unreadable clusters in it, optionally either remapping all of what it
  176.           reads from the disk or replacing bad sectors (the default) or clusters
  177.           with NULLs. HDTEST is not an alternative to backing up your floppies                                ___                                           
  178.           and/or hard disk - it may sometimes be able to save your neck when you                                    _________                                   
  179.           forgot or your backup went bad too! On hard disks which have developed
  180.           intermittent read errors, running HDTEST can sometimes totally cure                                                   ___                       
  181.           
  182.           
  183.                                           Page 2 
  184.            
  185.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  186.           
  187.           
  188.           the problem, presumably because the "flaky" sectors get rewritten and
  189.           the minor misalignments and/or weakening of the magnetic "image" which
  190.           were causing the trouble are corrected when the data is rewritten. In
  191.           its default ("slow") mode, HDTEST writes 20 different test patterns to
  192.           every cluster on the disk and checks that each pattern can be read          _____                                                             
  193.           back correctly, while preserving (and eventually restoring) the
  194.           contents of the clusters that contain data.  HDTEST can even (on many
  195.           devices) detect hard disk errors which are minor enough to be
  196.           correctable (and corrected) by the disk controller's own "error-
  197.           correcting code" (ECC).  These errors are normally totally invisible
  198.           to programs running under DOS and will not usually be picked up by
  199.           other disk test utilities.  They may, however, be early signs of
  200.           problems that will become significant later, and HDTEST consequently
  201.           marks these clusters, too, as bad. As long as HDTEST can read the data
  202.           from a flaky cluster correctly once (and it tries quite hard) it will
  203.           be able to save the file of which that cluster is a part intact, while                                                                   ______       
  204.           marking the cluster so that DOS does not try to use it again. The
  205.           program was designed to minimize the likelihood of user error causing
  206.           data loss on a good (or slightly bad) disk, and to be as easy as
  207.           possible to use - it could not be made very fast, since multiple bit
  208.           patterns have to be written to and read from each cluster, and this
  209.           takes a significant time even on a fast hard disk. The program does,
  210.           however, have a less sensitive "fast" test mode, which writes only two
  211.           test patterns to each block and is recommended for use when
  212.           testing/repairing floppy disks and/or to correct intermittent problems
  213.           or rule out gross problems on a hard disk.
  214.  
  215.           The program can be used to test/repair single and double-sided 8- and
  216.           9-sector minifloppies (if you have plenty of patience!), as well as                                             ______                          
  217.           AT-format 1.2Mb minifloppies, 8" standard floppies, and 3.5"
  218.           microfloppies (with the same proviso regarding a need for patience).
  219.  
  220.           HDTEST's companion program, HDCHEK, simply examines the logical
  221.           structure of the system and target device and gives a short report on
  222.           what it finds. It does not write to the disk, and is provided                                 ___                                   
  223.           principally to allow a quick and easy, but fairly reliable, check on
  224.           the compatibility between HDTEST and a given software/hardware
  225.           configuration. As part of its report, HDCHEK notes at what level (DOS
  226.           interrupts only, INT 13, or direct entry to the BIOS) it was able to
  227.           access the target device, which has a bearing on HDTEST's ability to
  228.           detect certain types of errors. In general, if HDCHEK runs                                          __________                
  229.           successfully on a system and target device, then HDTEST can be
  230.           expected to do so, although the latter program requires much more
  231.           available memory.
  232.  
  233.           The HDTEST package is distributed as "User-supported Software". If you
  234.           intend to continue using the program, you are required to become a
  235.           Registered user. Send a completed copy of the Registration Form (which
  236.           is included in this documentation), together with a check or money
  237.           order for $35.00 (+ $5.00 for shipping outside the continent of North
  238.           America) to me at the address which appears on the form. Please also
  239.           add $2.50 (or equivalent) if you want the software on a 1.2 Mb HD
  240.           
  241.           
  242.                                           Page 3 
  243.            
  244.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  245.           
  246.           
  247.           floppy or a 3.5" minifloppy, rather than a 360 Kb DSDD floppy, and
  248.           specify which you want on the Reg. form. Residents of Pennsylvania
  249.           should also add 6% Sales Tax to their order total. Checks and money
  250.           orders in denominations other than U.S. dollars are acceptable, but
  251.           please add a further $15.00 for bank charges before using the current
  252.           exchange rate to calculate the fee in the currency in which you are
  253.           paying. On receiving your Registration, I will send you a personalized
  254.           copy of the latest, enhanced, version of the HDTEST package (currently
  255.           V5.39), and register you for a year's support. Registration entitles
  256.           you to be notified of upgrades, bug fixes, newly discovered incompati-
  257.           bilities, etc., and to ask for (and get) necessary help in adapting
  258.           the program to work on your hardware. I cannot guarantee to make
  259.           HDTEST work with every possible combination of hardware and software,
  260.           but I will promise to try to solve problems as they come up, and I
  261.           will return your Registration fee if I cannot support HDTEST on your
  262.           system.  Support is available TO REGISTERED USERS ONLY by mail,                                        ________________________         
  263.           BIXmail, Compuserve EMail and telephone. Please also bear in mind that
  264.           my willingness and ability to continue to support and enhance these
  265.           programs will be directly dependent on users' willingness to pay the
  266.           Registration fee and (to some extent) inversely dependent on the
  267.           number of questions I get that could be answered by reading the docu-
  268.           mentation(!).
  269.  
  270.           The HD programs were written principally in C, compiled by the
  271.           Microsoft C compiler (Version 6.00A) using its "small" memory model,
  272.           and linked with code from the distributed Microsoft C object libraries
  273.           using the Microsoft Segmented Executable Linker (Version 5.13).
  274.           Portions of the distributed program are consequently Copyright (C) by
  275.           Microsoft Corp., 1985 - 1990. All rights reserved. These portions are
  276.           used under the terms of a license from Microsoft Corp. Some low-level
  277.           functions were written in assembly language and assembled by the
  278.           Microsoft MASM Macro Assembler (Version 6.00).
  279.  
  280.           These programs were written with care and have been tested on a number
  281.           of different systems.  I cannot, however, give any guarantee as to
  282.           their performance on a specific system, nor can I accept liability for
  283.           any actual or consequential loss resulting from their use. The
  284.           programs may only be used and/or copied in their original form.
  285.           Unauthorized modifications and/or the use of all or part of the
  286.           programs in other software, commercial or otherwise, are strictly
  287.           prohibited.
  288.  
  289.           The HD programs owe a lot of their value to suggestions and bug
  290.           reports (more of the former than the latter, fortunately) from
  291.           Registered users. They were originally written in response to a
  292.           "challenge" issued by Roedy Green on Bix, and their further
  293.           development has also been significantly influenced by his input. I
  294.           would also like to acknowledge the invaluable help of ltl, wlmoore,
  295.           and mike123 on Bix in beta-testing V5.xx of the program.
  296.  
  297.  
  298.  
  299.           
  300.           
  301.                                           Page 4 
  302.            
  303.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  304.           
  305.           
  306.  
  307.                               GETTING STARTED - INSTALLATION                              ______________________________
  308.  
  309.           1) If you received the HDTEST package on a disk, use the DOS DISKCOPY
  310.           program to make a duplicate of the distribution disk, put the original
  311.           away in a safe place, and use the duplicate as your working disk.
  312.           Otherwise, use COPY to save a copy of the HDTEST distribution files
  313.           on a floppy disk, and put it away.
  314.  
  315.           2) HDTEST does not require any special installation procedure. You may
  316.           run HDCHEK and HDTEST from a working floppy disk or from any
  317.           subdirectory on your hard disk. If you wish to keep and run the
  318.           programs on your hard disk, you will probably find it most convenient
  319.           to COPY them to a subdirectory which is one of those included in your
  320.           DOS PATH (see your DOS Reference Manual). Only the two main .EXE files
  321.           (HDTEST.EXE and HDCHEK.EXE) need normally be kept on-line.
  322.           BOOTLOAD.COM is only used or needed to create a special boot disk, if
  323.           you find you need to use one.
  324.  
  325.           3) If you wish to be able to refer to this documentation on-line, you
  326.           should follow the instructions in the README.1ST file in the
  327.           distribution package to produce a .TXT file (without underlining) and
  328.           keep that file in your documentation subdirectory.
  329.  
  330.  
  331.                              GETTING STARTED - TESTING A DISK                             ________________________________
  332.  
  333.           This section gives step by step instructions for running HDCHEK and
  334.           HDTEST, under IBM or "generic" MS-DOS, on the C: drive of a standard
  335.           IBM PC, XT, AT, or 100% compatible. Subsequent sections of this
  336.           documentation go into much more detail about some of the program's
  337.           other features and options, and should help to explain and let you
  338.           deal with any problems which you may encounter. Note that you should
  339.           never attempt to run HDTEST under a multi-tasking or multi-user          _____                                                          
  340.           operating system, nor activate any "pop-up" program (e.g. SideKick)
  341.           while the program is running. HDTEST is also incompatible with
  342.           programs (such as TIMEPARK) which are designed to move the heads of a
  343.           hard disk to a safe (or new!) area of the disk after a period of
  344.           inactivity. Such programs should be disabled or unloaded before
  345.           running HDTEST.
  346.  
  347.           1) Make sure that you have current backups of all the files on drive
  348.           C:. This is particularly important when running the program for the
  349.           first time on a system.
  350.  
  351.           2) Run DOS's CHKDSK program on drive C: and correct any errors
  352.           reported by it before proceeding further.
  353.  
  354.           3) Make the drive and/or directory which contains HDCHEK.EXE and
  355.           HDTEST.EXE your current drive and/or directory.
  356.  
  357.  
  358.           
  359.           
  360.                                           Page 5 
  361.            
  362.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  363.           
  364.           
  365.           4) If you are not running HDTEST from your A: drive, insert a
  366.           formatted, non-write-protected floppy disk in drive A. HDTEST will
  367.           write an ASCII log file called HDTESTC0.LOG to the disk in drive A -
  368.           any other files on it will be undisturbed.
  369.  
  370.           5) Give the command: "HDCHEK C:". After a certain amount of disk
  371.           activity has taken place, and certainly within a minute or two, your
  372.           screen should look like one of the examples given in Appendix C. If
  373.           any errors are reported, DO NOT PROCEED until you have read the rest                                   ______________                             
  374.           of the documentation and/or are sure you know what is going on.
  375.  
  376.           6) If HDCHEK reported no errors, give the command "HDTEST C: A:".             ____________________________                                  
  377.           After some disk activity, the program will prompt for replies to three
  378.           questions - press <Return> in response to each prompt. The program
  379.           will report its progress to the screen and will record any problems
  380.           encountered in the log file on the floppy disk. Depending on the size
  381.           of your DOS partition and the access time of the disk, a complete run
  382.           of HDTEST (in its normal, "slow", mode) will take between 2 and 5
  383.           hours. Your intervention will only be required if a recovered bad          _____                                                            
  384.           cluster is found in a "hidden", "system", or write-protected file,
  385.           when you will be asked to approve remapping; otherwise, bad clusters
  386.           will be automatically remapped. HDTEST can be aborted at any time by
  387.           pressing <Esc> or <Ctrl-Break> and responding to the "Are you
  388.           sure...." prompt by pressing <Return>.
  389.  
  390.           7) If HDTEST finishes testing without finding any bad clusters, it
  391.           will simply record that fact and the finishing time in the log file
  392.           and return to the DOS prompt. Otherwise, when read/write testing has
  393.           been completed (or terminated, by entering <Esc> or <Ctrl-Break>), you
  394.           will be prompted for permission to complete the remapping process by
  395.           updating the disk FATs and Directories.  Pressing <Return> will allow
  396.           this to take place, and you will then be returned to the DOS prompt.
  397.  
  398.           8) N.B. If HDTEST reported and remapped any bad clusters and you are             ____                                                  ___        
  399.           using the DOS (3.3 and above) FASTOPEN utility, or any other
  400.           directory- or file-cacheing software, you should reboot your system
  401.           after running HDTEST and before proceeding with any other work on it.                                   ______                 ___                  
  402.  
  403.           9) In any event, if HDTEST reported and remapped some bad clusters,
  404.           you should read the section on "Dealing with bad clusters" later in
  405.           this documentation.
  406.  
  407.  
  408.  
  409.  
  410.  
  411.  
  412.  
  413.  
  414.  
  415.  
  416.  
  417.           
  418.           
  419.                                           Page 6 
  420.            
  421.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  422.           
  423.           
  424.                              HARDWARE & SOFTWARE REQUIREMENTS                             ________________________________
  425.  
  426.           HDTEST and HDCHEK make a number of assumptions about the environment
  427.           in which they are operating. They will, generally speaking, abort with
  428.           an informative error message if they find one of these assumptions to
  429.           be untrue! They require MS/PC-DOS 2.x or above and (for HDTEST) up to
  430.           about 320 Kb of free memory (the exact amount required depends on the
  431.           size and other characteristics of the device being tested) to run -
  432.           the presence of more memory may (slightly) increase HDTEST's speed
  433.           when testing devices with large cluster sizes. The device to be tested
  434.           must be usable as a normal DOS device - commands such as DIR, COPY,
  435.           and CHKDSK should be valid for it and for files and subdirectories on
  436.           it. It need not, however, be bootable. Only the DOS-accessible
  437.           partition(s) of a multi-operating-system disk can be tested, but all
  438.           the partitions of a disk that is divided into multiple DOS-accessible                                                                 ______________
  439.           partitions can be tested (one by one). This version of HDTEST fully
  440.           supports DOS 3.3 (and above) extended partitions, and will test them
  441.           as thoroughly as it does normal DOS partitions. It also allows BIOS-
  442.           level testing of the DOS-compatible "proprietary" partitions created
  443.           by SpeedStor and Disk Manager. HDTEST's support for other disk
  444.           partitioning software is provided only to the extent that DOS support
  445.           is provided by the producers of that software.
  446.  
  447.           If you wish to use HDTEST to test a new hard disk which is to be                                       ____                               
  448.           configured to support multiple operating systems, you should first
  449.           configure it as one or more DOS-accessible partitions, test it in that
  450.           configuration, and then reconfigure it as you intend to use it. If you                                  __                                            
  451.           have low-level disk formatting software which allows you to specify
  452.           bad sectors and/or tracks to be "locked out", you can use HDTEST's /G
  453.           option on the DOS partition(s) to produce a list of defects, which can
  454.           then be used in reformatting the disk. Note that HDTEST can only be                                                                      ____   
  455.           used as a test for areas of the disk that are to be devoted to other                    ____                                                      
  456.           operating systems - when you repartition the disk, any remapping
  457.           and/or marking of bad clusters which HDTEST may have done in the DOS
  458.           partition is lost, unless you use information given by the /G option
  459.           to redo the low-level format.                      _________        
  460.  
  461.           Ideally, for normal hard disks, the BIOS handler for interrupt 13
  462.           should be capable of handling (at least) normal disk reads and writes
  463.           (sub-functions 2 and 3) in a way that is compatible with that
  464.           documented for the XT hard disk adapter (and AT BIOS) in IBM's
  465.           technical documentation. This should be no problem for most disk
  466.           systems on IBM PCs and most compatibles.  HDTEST may, however, be
  467.           forced to use the (somewhat more limiting) DOS device interface when
  468.           used with non-bootable hard disks and/or with hard disks which require
  469.           special device drivers (other than those provided with the SpeedStor
  470.           and Disk Manager partitioning software) to be installed, and may also
  471.           be forced to use the DOS device interface when dealing with disks
  472.           partitioned by means other that the DOS 3.3 (and above) FDISK
  473.           utilities.
  474.  
  475.  
  476.           
  477.           
  478.                                           Page 7 
  479.            
  480.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  481.           
  482.           
  483.           Early V4.xx releases of HDCHEK and HDTEST would abort if run on small
  484.           (<= 10 Mb) hard disks which had been patched to use a cluster size
  485.           smaller than the DOS standard (and 16-bit FATs). This deficiency was
  486.           corrected in later V4.xx releases, but very small (less than 1024
  487.           clusters) partitions may still cause problems if 16-bit FATs are used
  488.           (there is no good reason why such partitions should use 16-bit FATs).
  489.  
  490.           By default, if run under DOS 3.0 or above on an IBM INT 13 compatible
  491.           hard disk, The HD programs attempt to locate and use the ROM BIOS INT
  492.           13 entry point, rather than the normal INT 13 vector (which DOS 3.x
  493.           and above intercepts and interferes with). By default, for machines
  494.           with 8088, 8086, 80188, 80186, or equivalent NEC CPUs the programs
  495.           assume that, if a ROM is present at absolute address C8000H, it                       ___________________                               
  496.           contains the hard disk BIOS and has initialization code starting at                                      ___                                    
  497.           offset 3. This assumption is true for all hard disks which "plug in"
  498.           to the IBM PC and XT. It may not be true for all clones which come
  499.           with hard disks installed, although it is likely to be true for most
  500.           of them. Also by default, the programs assume that the hard disk BIOS
  501.           in systems with 80286 or 80386 processors is in the "system" ROM at
  502.           absolute address F0000H, but make no more specific assumptions about                                            __                                
  503.           its exact location. Problems (up to and including system halts) may
  504.           occur if none of the special flags is set and your system is
  505.           configured in a way that is not consistent with these assumptions.
  506.           Such problems are almost guaranteed for PC or XT systems if the
  507.           initialization code does not start at offset 3 in the ROM. If you know
  508.           that your hard disk ROM is located somewhere other than at the default
  509.           segment address and/or does not obey the "rules", you can use the /H
  510.           flag to tell the programs where to look for it. Unless you know that
  511.           your system is particularly non-IBM-compatible, however, it is usually
  512.           worth trying to run the HD programs in their default mode first.
  513.           Problem hardware should respond to one of the approaches described in
  514.           the "Using the On-Disk Preboot" section of this documentation. The use
  515.           of all the command line flags is discussed in more detail below.
  516.  
  517.           Note that, since HDTEST remaps bad clusters to free space, there is
  518.           not much point in running it on a disk which has none (as shown by DIR
  519.           or CHKDSK), since the program will abort immediately if it finds a bad
  520.           cluster.  Unless you have a really flaky disk, however, you should not
  521.           need more than a couple of hundred Kb of free space to remap any
  522.           reasonably probable number of new bad clusters.
  523.  
  524.           This version of the HD programs does not require an ANSI console
  525.           driver (such as ANSI.SYS) to be loaded. The programs will, however,
  526.           continue to function correctly if such a driver is present.
  527.  
  528.  
  529.  
  530.  
  531.  
  532.  
  533.  
  534.  
  535.           
  536.           
  537.                                           Page 8 
  538.            
  539.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  540.           
  541.           
  542.                                LIMITATIONS AND RESTRICTIONS                               ____________________________
  543.  
  544.           HDTEST still has a few (mainly theoretical) limitations, most of which
  545.           result from the way data is stored internally by the program. None of
  546.           them are "etched in stone", although some could only be avoided at the
  547.           cost of slowing down what is already (and necessarily) far from a fast
  548.           program. The known limitations are as follows:
  549.  
  550.           1) Maximum cluster size = 65,528 bytes. I do not believe that a DOS
  551.           disk can ever have clusters larger than 64 Kb, but my limit is a few
  552.           less than that and may, since sector and cluster sizes tend to run in
  553.           powers of 2, effectively limit cluster size to 32 Kb - this should be
  554.           enough for most people!.
  555.  
  556.           2) Because of certain limitations of the chips used to support direct
  557.           memory access (DMA, the method used to transfer data from disk to
  558.           memory and vice versa) in the IBM PC and most of its early clones and
  559.           compatibles, HDTEST may be unable to use available memory efficiently
  560.           when cluster sizes (and the buffers needed to hold them) are large.
  561.           This inefficiency can result in "Insufficient Memory" or "Memory
  562.           Allocation" errors, even on systems with more than the minimum 320 Kb
  563.           of free memory prescribed above. The only cure for this is to free up
  564.           (or buy!) more memory (remove RAMdisks, remove resident software,
  565.           etc.). Work is in progress on a version of HDTEST which can make more
  566.           extensive use of LIM 4.0 expanded memory for its buffers. Contact me
  567.           if you would like a preliminary copy of this version.
  568.  
  569.           3) The current version of HDTEST will run, in its default mode, on ATs
  570.           and most AT clones, but may not be able to detect corrected ECC errors
  571.           when run in default mode on some of the clones - a warning message
  572.           will be displayed when the program initializes itself if corrected ECC
  573.           errors are not being detected. Appropriate use of the extended form of
  574.           the /H flag or the /U flag, as described in the "Using the On-Disk
  575.           Preboot" section of this documentation, will allow detection of
  576.           corrected ECC errors on almost all hardware. The program will not                                                                        ___
  577.           detect corrected ECC errors when invoked with the /I flag (under DOS
  578.           3.0 or above) or with the /D flag.
  579.  
  580.           4) For reasons which are poorly understood (at least by the author!),
  581.           HDTEST runs very slowly on Epson Equity II systems, particularly when                      ____                                                     
  582.           used to test "plug-in" hard drives of the "Hardcard" or "Flashcard"
  583.           variety. For this hardware, the estimated run times given elsewhere in
  584.           the documentation need to be multiplied by about 2.5. There is some                                       __________          ___               
  585.           reason to think that this problem may be related to an excessively
  586.           "optimistic" interleave setting on (at least) some of these systems.
  587.  
  588.           5) HDTEST or HDCHEK will, by default, abort with an informative error
  589.           message if the program detects that the (80286 or better) CPU that it
  590.           is running on is not in "real" mode, since this normally means that a
  591.           (possibly multitasking) OS other than MS/PC-DOS is running and that
  592.           HDTEST cannot be guaranteed unchallenged access to the hardware. The
  593.           presence of LIM 4.0 expanded memory emulators such as QEMM-386 or
  594.           
  595.           
  596.                                           Page 9 
  597.            
  598.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  599.           
  600.           
  601.           386^Max, which use the 80386's "virtual 8086" mode to allow remapping
  602.           of extended memory into unoccupied space in the area between 640 Kb
  603.           and 1 Mb, will cause a similar abort, unless the driver is inactive
  604.           (turned "OFF"). This safety feature can be bypassed by the use of the
  605.           /V command line option (see below).
  606.  
  607.           6) HDCHEK and HDTEST will operate normally (except than the /U or /H
  608.           flags will sometimes be needed to use the low-level interface) on
  609.           (very large) hard disks with more than 1024 cylinders, provided that
  610.           the partition being tested does not begin or end above cylinder 1023.                                                    ______                     
  611.           HDTEST now supports the SpeedStor and Disk Manager extensions to INT
  612.           13, which allow access to cylinders beyond cylinder 1023. To use the
  613.           HD programs on partitions which span or start above cylinder 1024,
  614.           follow the instructions in the section of this document entitled:
  615.           "Using the HD programs with SpeedStor and Disk Manager". Otherwise, by
  616.           default, if the partition starts below and ends above track 1023,
  617.           HDCHEK will issue a warning and HDTEST will abort unless the /D flag
  618.           is used. If the partition starts above cylinder 1023, both HDCHEK and
  619.           HDTEST will, by default, abort.
  620.  
  621.  
  622.                                    COMMAND LINE OPTIONS                                   ____________________
  623.  
  624.           Always run HDCHEK on any new hardware/software configuration before          ______                                                             
  625.           you attempt to run HDTEST (at least the first time). The latter
  626.           program has been written as conservatively as possible, but it is not
  627.           possible to predict the behavior of every conceivable combination of
  628.           hardware and operating system when dealing with a program which
  629.           bypasses most of the controls which normally protect the user from
  630.           destroying his world. HDCHEK is invoked with the command line:
  631.  
  632.           HDCHEK device [optional parameters]
  633.  
  634.           "optional parameters" may include one or more of the following:
  635.  
  636.           [/A] [/Cn | /CQ] [/D | /Ex | /I | /U] [/Hnnnn[:nnnn]] [/M] [/V]
  637.  
  638.           "device" is the device to be tested (e.g. A:, B:, etc. - the colons
  639.           are permitted but not required). For versions of HDCHEK from V4.35,                            ___                                              
  640.           the spaces between the device identifier and the flags (and between
  641.           different flags) are optional - the command lines "HDCHEK C:/C2/D" and
  642.           "HDCHEK C: /C2 /D" are equivalent.
  643.  
  644.           The /A(T) flag is used to tell the HD program that it is being run on
  645.           an IBM AT. Setting the /A flag allows the programs to deal correctly
  646.           with a known bug in the IBM AT floppy disk controller BIOS when HDTEST
  647.           is used on 1.2 Mb "AT format" 5.25" floppy disks. If the /A flag is
  648.           set and the CPU is not an 80286 or better, you will be asked to
  649.           confirm that you wish to use AT defaults (HD BIOS at F0000H).
  650.  
  651.           N.B. the definition of the /A flag changed (slightly) at V4.71 - it          ___________________________________________________________________
  652.           need now only be used if you are testing a 1.2 Mb floppy disk on a          __________________________________________________________________
  653.           
  654.           
  655.                                          Page 10 
  656.            
  657.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  658.           
  659.           
  660.           "vanilla" IBM AT. It may still be used to change the default BIOS          _________________________________________________________________
  661.           segment to F0000H on a PC or XT class machine, but the use of the /H          ____________________________________________________________________
  662.           flag for this purpose is preferred.          ___________________________________
  663.  
  664.           The /C flag has two variants. It is used, immediately followed by a
  665.           single decimal digit ("n") in systems which do not support IBM's INT
  666.           11 "equipment determination" BIOS function (e.g. the Tandy 2000). The
  667.           parameter ("n") is the number of internal floppy drives attached to
  668.           the system, which would otherwise be determined by the program, using
  669.           INT 11. The second variant should be used on Compaq computers - here,
  670.           the flag is followed by a "Q", instead of a number. This variant
  671.           enables large device support (as for IBM DOS 4.00) under Compaq DOS
  672.           3.31.
  673.  
  674.           The /D(OS interrupts) flag forces HDCHEK to use the hardware-
  675.           independent DOS interrupt 25 for access to the target device. It is
  676.           usually not required, since the program is usually smart enough to          _______                                    _______                
  677.           recognize devices which have to be accessed this way (e.g. logical
  678.           disk partitions other than those created as DOS 3.3 (and above)
  679.           "Extended Devices", non-bootable hard disks, some removable-media hard
  680.           disks). If the /D flag is not used, the program will issue a warning                                    ___                                       
  681.           message if it finds it has to use the DOS interrupts.
  682.  
  683.           N.B. the definition of the /D flag changed at V4.00 - the new /I flag          _____________________________________________________________________
  684.           has the same effect as the old (pre-V4.00) /D flag. Only one of these          _____________________________________________________________________
  685.           flags may be present on the command line.          _________________________________________
  686.  
  687.           The /E(xtended INT 13) flag permits HDCHEK to recognize "proprietary"
  688.           SpeedStor or Disk Manager partitions and allows the use of the
  689.           "extended" INT 13 definitions which permit SpeedStor and Disk Manager
  690.           to support disks with more than 1024 cylinders. Use /ES to use
  691.           SpeedStor extensions and /ED for Disk Manager extensions. See the
  692.           "Using the HD programs with SpeedStor and Disk Manager" section of
  693.           this documentation for further details.
  694.  
  695.           The /I(nterrupt 13) flag has no effect under DOS 2.x.  Under DOS 3.0
  696.           or above, it forces HDCHEK to use the existing INT 13 vector (which it
  697.           always does under DOS 2.x), and prevents the program from trying to
  698.           determine the ROM BIOS entry point; the flag should be used if you
  699.           know that your system's fixed disk BIOS uses INT 13 but does not
  700.           follow IBM's "rules" or if the program crashes the system when invoked
  701.           without it.
  702.  
  703.           The /H(ex BIOS address) flag is normally used (with a single numeric
  704.           argument) to tell the HD programs that the ROM BIOS of the device
  705.           being tested is located at nnnn, which is interpreted as a Hexadecimal
  706.           segment address, rather than at C800, which is the default for PC and
  707.           XT class machines, or F000, which is the default for systems using a
  708.           80286 or better CPU. There must be no space between the H and the
  709.           number. The extended form of the /H flag (e.g. /HF000:80D5) forces the
  710.           HD programs to use the given address as the ROM BIOS INT 13 entry                                               ____________________________
  711.  
  712.           
  713.           
  714.                                          Page 11 
  715.            
  716.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  717.           
  718.           
  719.           point. Its use is documented in more detail in the "Using the On-Disk          _____                                                                
  720.           Preboot" section of this documentation.
  721.  
  722.           The /M(ulti-track read problem) flag forces HDCHEK to split up disk
  723.           accesses that would otherwise require the BIOS to read data from more
  724.           than one track in a single "bite". Its use is documented in more
  725.           detail in the "Using the On-Disk Preboot" section of this
  726.           documentation.
  727.  
  728.           The /U(se INT 68) flag forces the HD programs to use the existing INT
  729.           68 vector (which must have been set up to point to an appropriate
  730.           location!) instead of locating and using the INT 13 BIOS entry point.
  731.           The use of this flag is documented in more detail in the "Using the
  732.           On-Disk Preboot" section of this documentation.
  733.  
  734.           The /V(irtual mode) flag bypasses the code which prevents the HD
  735.           programs from working when the (80286 or better) CPU is not in "real
  736.           mode". It should only be used when the programs are being run under a                           ____                                                
  737.           single-tasking operating system which is using "virtual mode" only for                                                                        ____    
  738.           memory-mapping. Certain LIM 4.0 expanded memory emulators for 386
  739.           machines use the processor's virtual mode for this purpose. The two
  740.           most well-known examples of this type of software are QEMM-386 and
  741.           386^Max. The HD programs are "DESQview aware", and will abort if run
  742.           under DESQview, even if the /V flag is used. They will not be able to
  743.           protect you from the (probably disastrous) consequences of using the
  744.           /V flag to run them under other multi-tasking OSes (such as VM-386).
  745.  
  746.           After a short delay, during most of which the specified device will be
  747.           active, a description of the device's logical structure will be disp-
  748.           layed.  After a further delay, and more disk activity, a message will
  749.           be printed giving the number of files and subdirectories found on the
  750.           disk, and the program will exit back to DOS. Note that the total
  751.           number of files and subdirectories reported by HDCHEK will be greater
  752.           than the sum of the counts reported by CHKDSK. This is because HDCHEK
  753.           counts the "." and ".." entries in subdirectories and CHKDSK doesn't.
  754.  
  755.           Errors and/or problems encountered, if any, will be reported on in
  756.           some detail. A number of example screen displays and log files
  757.           produced by running HDCHEK (and HDTEST) on different systems will be
  758.           found in Appendix C at the end of this documentation. If HDCHEK tells
  759.           you that you have a bad 8088 chip, believe it - some early 8088s had a
  760.           bug which allowed them to be interrupted while changing their stack
  761.           frame*  - this is not benign, and can cause all sorts of rare,
  762.           otherwise almost inexplicable, problems. The only real cure is to
  763.  
  764.           _____________________________________________________________________
  765.  
  766.           * See "Chips in Transition", by Bob Smith. PC Tech J. 4:4 (Apr. 1986):                                                     __________                 
  767.           56-69. The code which the HD programs use to identify the CPU and
  768.           diagnose this problem is adapted from the CPUID program described in
  769.           this article and from code from subsequent, related, articles in that
  770.           (now defunct) magazine.
  771.           
  772.           
  773.                                          Page 12 
  774.            
  775.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  776.           
  777.           
  778.           replace the CPU (which is, fortunately, not a particularly expensive
  779.           proposition these days). If HDCHEK reports a discrepancy between the
  780.           two FATs, HDTEST will abort. The FIXFAT program (on the distribution
  781.           disk) may be able to correct this problem - see FIXFAT.DOC, also on
  782.           the distribution disk. 
  783.  
  784.           Always run the DOS CHKDSK program immediately before running HDTEST on
  785.           a disk. If CHKDSK reports any problems, its /F option (or other means)
  786.           should be used to correct them before HDTEST is run.                                         ____________________ 
  787.  
  788.  
  789.           HDTEST is invoked with the command line:
  790.  
  791.                HDTEST device1 [device2[:pathname]] [optional parameters]
  792.  
  793.           "optional parameters" may include one or more of the following:
  794.  
  795.           [/A] [/B] [/Cn | /CQ] [/D | /Ex | /I | /U] [/F] [/G[V]] [/Hnnnn[:nnnn]]
  796.           [/M] [/N] [/P] [/R[n]] [/Snnnnn] [/V] [/X] [/Yn] [/Z[n]]
  797.  
  798.           "device1" is the name of the device to be tested, as for HDCHEK.
  799.           "device2" (which, if present, must be different from "device1") is the                                        ____                                    
  800.           name of a device on which a log file is to be written. The device name
  801.           may be immediately followed by a file- or path-name for the log file.
  802.           If only a device name (with or without a colon) is specified for the
  803.           log file, a file called HDTESTdn.LOG will be written to the default
  804.           directory on the specified device. "d" in this file specification is
  805.           replaced by the single-character specifier of the device being tested,
  806.           while "n" is replaced by the lowest decimal digit which results in the
  807.           creation of a new file (previous log files will not normally be                        ___                               ___            
  808.           overwritten). If all ten possible log file names for this test device
  809.           have already been used, the program will prompt for a new name. If a
  810.           directory path (ending in a backslash (\)) is specified as device2,
  811.           HDTESTdn.LOG will be created in the specified directory. If a full
  812.           pathname is specified (not ending in a backslash), a file with that                                 ___                                         
  813.           pathname will be opened as the log file. In this case (only), any pre-
  814.           existing file of the same name will be overwritten. If "device2" is
  815.           not specified, errors are reported to the console terminal. The DOS
  816.           console redirection facility should not be used to redirect them                                              ___                         
  817.           elsewhere.
  818.  
  819.           For versions of HDTEST from V4.35, the spaces between the device
  820.           identifier and the flags (and between different flags) are optional -
  821.           the command lines "HDTEST C:/A/F" and "HDTEST C: /A /F" are
  822.           equivalent.
  823.  
  824.           The /A, /C, /D, /E, /H, /I, /M, /U, and /V flags have the same meaning
  825.           and effect that they do for HDCHEK. When used for HDTEST, the /D flag
  826.           forces the use of INT 25 to read from and INT 26 to write to the
  827.           target disk.
  828.  
  829.  
  830.           
  831.           
  832.                                          Page 13 
  833.            
  834.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  835.           
  836.           
  837.           The /B(oot/Partition sector test) flag forces the program to include
  838.           the boot/partition sector (track 0, head 0, sector 1) in the DOS area
  839.           for the purposes of read/write testing. The default action is only to
  840.           perform read and seek tests on this sector, even if read/write testing
  841.           of the DOS area is specified. Since the boot/partition sector is
  842.           effectively read-only under normal circumstances (it is only written                                                                       _______
  843.           to during low-level formatting, and by FDISK and other disk          __                                                         
  844.           partitioning programs), read/write testing is less vital than for the
  845.           rest of the disk. In addition, at least one hard disk controller (a
  846.           Western Digital board which allows a single disk to be addressed as
  847.           two "physical" devices) will not allow test patterns to be written to
  848.           this sector. Certain devices (chiefly RAMdisks) appear to DOS to be
  849.           hard disks but do not, in fact, possess boot/partition sectors. On
  850.           these devices, HDTEST will report check/test results on the
  851.           boot/partition sector while actually reading/writing the device's boot
  852.           sector - the latter sector will simply end up being checked/tested
  853.           twice under these circumstances.
  854.  
  855.           The /F(ast mode) flag causes the program to use only two test patterns
  856.           (all 1s and all 0s) for read/write testing. It is intended for use on
  857.           floppy disks and for "quick and dirty" testing of other devices.
  858.  
  859.           The /G(ive error details) flag causes the program to determine the
  860.           location of errors occurring during testing of the disk's data area at
  861.           the sector level (they are normally handled at the cluster level), and
  862.           to report on the physical location of all bad sectors found. The
  863.           report is written to the log device or file after all testing is                                                      ____________________
  864.           finished. By default, only an error code is given for each bad sector          ________                                                             
  865.           - if a V (for "verbose"!) is appended to the flag, the error code is
  866.           expanded to a report similar to that given for each bad cluster. This
  867.           flag is ineffective (and ignored) if HDTEST is using DOS interrupts,
  868.           either because the /D flag was set or because the program was not able
  869.           to access the disk at the BIOS level.
  870.  
  871.           The /N(o Query) flag disables the individual prompts for confirmation
  872.           which the program normally issues before remapping clusters which are
  873.           marked as "Reserved" or which are part of a file which is marked as
  874.           "System", "Hidden", or "Readonly".  The /N flag does not prevent the                                                               ___            
  875.           program from prompting for confirmation before updating the disk.
  876.  
  877.           The /P(rint) flag causes the log file to be directed to the PRN device
  878.           (normally LPT1), and overrides any "device2" specification.
  879.  
  880.           The /R(epeat)n flag causes HDTEST to go through n complete testing
  881.           cycles. Omitting n, or setting it to zero, causes HDTEST to run
  882.           continuously until terminated by pressing <Esc>). Instead of stopping
  883.           after completing the testing of allocated data clusters, the program
  884.           immediately starts again with the DOS area. Any bad clusters found and
  885.           flagged in the first pass should be reported as "already marked as
  886.           bad" in subsequent passes. The /R flag implicitly sets the /N flag and
  887.           disables the program's incremental testing functionality.
  888.  
  889.           
  890.           
  891.                                          Page 14 
  892.            
  893.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  894.           
  895.           
  896.           The /S(tart)nnnnn flag became largely obsolete with version 5.32 of
  897.           HDTEST. It causes HDTEST to start testing occupied clusters at cluster                                                    ________                    
  898.           number nnnnn (expressed as a decimal number). There must be no space                                       _______                                
  899.           between the "S" and the number. This option was mainly useful when a
  900.           previous run of HDTEST had been interrupted (by pressing <Esc> or
  901.           <Ctrl-C>), since it allowed you to start testing occupied clusters                                                           ________         
  902.           where you had left off. In order to be sure that data was not remapped
  903.           to a bad area, HDTEST always tested all empty clusters before starting                                ______        ___                               
  904.           to test occupied clusters. For this reason, using the /S flag did not
  905.           result in a large time saving if the target disk was nearly empty, and
  906.           it made the most difference on a full, or nearly full, disk. From
  907.           version 5.32, HDTEST defaults to "picking up where it left off" after
  908.           a run is interrupted. See the "Incremental Disk Testing" section for
  909.           further details.
  910.  
  911.           The /Y(es, please remap)n flag causes HDTEST to remap up to n (a
  912.           decimal number) bad clusters without prompting for confirmation. It is
  913.           effective only if HDTEST is allowed to run to completion, and is
  914.           intended to allow the program to be run unattended on multiple disks
  915.           from a .BAT file. If more than n bad clusters are found or if the
  916.           program is aborted (by pressing <Esc>), the normal prompt for
  917.           confirmation is issued before any bad clusters are remapped. See
  918.           "Running HDTEST from a .BAT file".
  919.  
  920.           The /X(clude bad clusters) flag causes HDTEST not to test clusters                                                        ___                 
  921.           that are already marked as bad by FORMAT or previous runs of HDTEST
  922.           (the default is to test all clusters every time the program is run).                                  ___                                         
  923.           This saves some time when testing a disk with a substantial number of
  924.           known defects. The marked clusters will be reported as bad but will
  925.           not be retested. The /X flag overrides the /G flag for previously
  926.           marked clusters - no bad sector report will appear for these clusters
  927.           if both flags are used.
  928.  
  929.           The /Z(ero bad sectors)n flag controls how HDTEST deals with sectors
  930.           that could not be read correctly (due to unrecoverable read errors)
  931.           when it remaps bad clusters. Versions of HDTEST up to and including
  932.           V4.10 (somewhat cavalierly) disregarded the remaining contents of the
  933.           entire cluster if one or more sectors in it were unreadable, and
  934.           remapped it to a cluster of NULLs. The default action is now to
  935.           replace only the unreadable sector(s) with NULLs, transferring the                                      _________                             
  936.           remaining sectors intact to the remapped cluster. There are, however,
  937.           two other options, which can be chosen by setting n to 0 or 2 (if n is
  938.           omitted, 1, or any other number, the default action is taken). Setting
  939.           n to 0 uses the old default (remaps the bad cluster to a cluster of                          ___                                      _______   
  940.           NULLs), while setting n to 2 goes to the other extreme and copies all
  941.           data read (some of which is almost certainly invalid) to the remapped
  942.           cluster. It is always safe and often advisable to use the /Z2 option
  943.           provided that you do not try to use any non-ASCII files that have been          ______________________________________________________________________
  944.           remapped with unrecovered read errors and the /Z2 option. Remapped          _________________________________________________________         
  945.           ASCII files can be inspected with an editor and fixed up where
  946.           necessary - non-ASCII files (e.g. .EXE, .COM, .WKS files) may appear
  947.           to be undamaged (the program may run, the worksheet be readable, etc.)
  948.           
  949.           
  950.                                          Page 15 
  951.            
  952.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  953.           
  954.           
  955.           but they can still contain small changes which will cause trouble
  956.           later, and they cannot easily be checked. The large "holes" which /Z
  957.           options 0 and 1 leave in such files usually allows it to be much more
  958.           obvious that they are defective!
  959.  
  960.  
  961.                                    WHAT DOES HDTEST DO?                                   ____________________
  962.  
  963.           The following discussion assumes that both any immediately previous
  964.           run of HDTEST on the target device and the current run was and is
  965.           allowed to run to completion. HDTEST's new (V5.32) incremental testing
  966.           functionality is discussed in the "Incremental Disk Testing" section
  967.           of this documentation.
  968.  
  969.           After displaying its copyright message, HDTEST reads the FATs and
  970.           scans the root directory and all subdirectory trees of the specified
  971.           device before initiating a short dialogue. All questions are of the
  972.           "Yes/No" type and should be answered by typing "Y" or "N" (case does
  973.           not matter) and pressing the <Return> key.  Pressing the <Return> key
  974.           alone is equivalent to giving the default response (which appears in
  975.           square brackets at the end of each prompt).  HDTEST then proceeds to
  976.           test the specified device. By default, the DOS area (boot sector,
  977.           FATs, and root directory) is not subjected to Read/Write testing,
  978.           since failures in this area usually make themselves apparent fairly
  979.           rapidly. The user can, however, choose to run these tests on the DOS
  980.           area too, or to limit testing to read and seek tests only over the
  981.           whole partition.
  982.  
  983.           In its reports to the screen, HDTEST uses the convention that read-
  984.           only testing is "Checking" while read/write testing is "Testing" - it
  985.           always "checks" the boot/partition sector and the rest of the DOS
  986.           area, but only "tests" them if requested to do so.
  987.  
  988.           In "checking" or "testing" a block (sector or cluster), HDTEST first
  989.           reads it (retrying, if necessary, up to five times) and then does the
  990.           longest possible seek away from it before attempting to read it again.
  991.           "Checking" is complete at this point. "Testing" continues with the
  992.           program sequentially writing 20 (or 2, for "fast mode") different bit
  993.           patterns to the block and checking that each one can be read
  994.           correctly, before rewriting the original contents of the block (and
  995.           reading it again to ensure that it has been restored correctly).
  996.           Errors that occur at any point in this process are reported and (if
  997.           the block is in the data area - errors in the DOS area are always
  998.           treated as fatal) the block is remapped. If an error is detected in a
  999.           "Reserved" cluster or in one that is part of a file which is marked as
  1000.           "System", "Hidden", or "Readonly", the user is normally asked for
  1001.           confirmation before the cluster is remapped, otherwise it is assumed
  1002.           that remapping is desired.
  1003.  
  1004.           HDTEST keeps a copy of the FAT and a map of the device's directory
  1005.           structure in memory. A bad cluster is remapped by transferring its
  1006.           contents to a free cluster and (if the bad cluster was in use)
  1007.           
  1008.           
  1009.                                          Page 16 
  1010.            
  1011.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  1012.           
  1013.           
  1014.           changing all necessary FAT and directory entries in memory so that the
  1015.           pointer chain which maintains the structure of the affected file or
  1016.           subdirectory remains valid. The bad cluster's FAT entry is then
  1017.           altered to identify it as bad to DOS. The device's FATs and                                                    ________         
  1018.           directories are not altered until the whole device has been scanned,
  1019.           and then only after the user has confirmed that it is OK to proceed.
  1020.           This means that a power failure and/or an inadvertent power-off which
  1021.           occurs while the program is running will cause the loss of, at most,
  1022.           one cluster of data and of no FAT or root directory information
  1023.           (unless you are very unlucky and it happens after you have confirmed                          ____                                                
  1024.           that you want a damaged data area to be remapped and while this is
  1025.           being done). If a power failure and/or power-off occurs while a
  1026.           cluster which contains the directory information of a subdirectory is
  1027.           being tested, part or all of that subdirectory will probably become
  1028.           inaccessible to DOS, although the data in it will remain on the disk
  1029.           and be potentially recoverable with the aid of (e.g.) the Norton
  1030.           Utilities (TM).
  1031.  
  1032.           You can safely interrupt the testing process part way through (by
  1033.           pressing the <Esc> or <Ctrl-Break> key) with no risk of leaving a
  1034.           partially updated FAT or directory. If you do interrupt the program in
  1035.           this way, you will be given the option of updating the disk, so that
  1036.           bad clusters which were detected before it was interrupted can be
  1037.           remapped. The program will also create a file (HDTESTED.MP0) in the
  1038.           root directory of the target disk which a subsequent run of HDTEST can
  1039.           read to identify clusters that have already been tested. See the
  1040.           "Incremental Disk Testing" section of this documentation for more
  1041.           discussion of this area.
  1042.  
  1043.           Errors which occur in the program's initialization phase cause it to
  1044.           abort with an error message and (sometimes) a hexadecimal error code.
  1045.           The meaning of the error code is context-dependent and it is useful
  1046.           only to technical support personnel (i.e. the author!). Errors
  1047.           detected during read-write testing only cause the program to abort if
  1048.           they occur during testing of the DOS area, or if remapping is
  1049.           impossible (only likely to happen if the disk is full). In any event,
  1050.           a description of the error is written to the log file (if any) and/or
  1051.           to the screen. This specifies the cluster or (for the DOS area) sector
  1052.           number and the name of the affected file (if any), and defines the
  1053.           type(s) of error which occurred. Appendix B contains a discussion of
  1054.           some of the more technical aspects of data storage on disks (floppy
  1055.           and hard), and includes more information about some of the possible
  1056.           errors that may be encountered.
  1057.  
  1058.           HDTEST takes a very long time to run to completion because of the                         ____                                              
  1059.           large number of reads and writes it does for each cluster. A typical
  1060.           time for full testing ("slow" mode) of an XT disk (10 Mb) would be 2
  1061.           hrs; full disk testing on a 30 Mb Enhanced AT takes at least 4 hrs.
  1062.           Note also that using the /D or /G flags will substantially slow down
  1063.           the testing of disks with significant numbers of bad spots. Using the
  1064.           /X flag as well will allow the physical location of new defects to be
  1065.  
  1066.           
  1067.           
  1068.                                          Page 17 
  1069.            
  1070.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  1071.           
  1072.           
  1073.           reported without requiring that known bad areas be exhaustively
  1074.           retested.
  1075.  
  1076.  
  1077.                                  INCREMENTAL DISK TESTING                                 ________________________
  1078.  
  1079.           In response to a considerable number of requests, mainly from users
  1080.           with very large disks and/or partitions, on which HDTEST took a very
  1081.           long time to run to completion, the program has been revised to allow
  1082.           true "incremental" testing of the data area. When a run of HDTEST is
  1083.           interrupted by the user pressing <Esc> or <Ctrl-Break> during testing
  1084.           of the data area, the program writes a special file (HDTESTED.MP0) in
  1085.           the root directory of the target disk before exiting. This file
  1086.           contains a bitmap of the data area of the disk, with set bits
  1087.           indicating clusters that have been tested, and a six-byte header which
  1088.           a subsequent run of HDTEST can use to ensure that the file has not
  1089.           been corrupted. After HDTEST writes the file, the program gives it the
  1090.           "READ ONLY" attribute, so that it will not be accidentally deleted or
  1091.           modified. If a subsequent invocation of HDTEST finds HDTESTED.MP0 in
  1092.           the root directory of the target disk, the program will ask if you
  1093.           want to use the information in the file to allow it effectively to
  1094.           start where the previous run left off. If the file is less than 14
  1095.           days old, the default answer to this query is "Y"; if the file is
  1096.           older, the default answer is "N". If the new invocation of HDTEST runs
  1097.           to completion, HDTESTED.MP0 will be deleted; if the new invocation is
  1098.           again interrupted, the file will be updated with bits set for any
  1099.           additional tested clusters. Note that every run of HDTEST will check
  1100.           or test the entire DOS area of the disk. Only the data area is
  1101.           potentially subject to incremental testing. Note also that it does not
  1102.           matter if files are written or deleted between "incremental" runs of
  1103.           HDTEST. Newly freed clusters will be tested before any occupied                  _____                                                  
  1104.           clusters, even if the previous run had included all (then) free
  1105.           clusters, and previously free clusters now included in files will be
  1106.           skipped, but the program will not become confused or miss any untested
  1107.           clusters because the contents of the disk may have changed.
  1108.  
  1109.  
  1110.                                 USING THE ON-DISK PRE-BOOT                                __________________________
  1111.  
  1112.           All "normal" PCs and almost all clones capable of running IBM PC-DOS
  1113.           (rather than "generic" MS-DOS) should also run the HD programs with no
  1114.           problems, and should allow them to locate and use the ROM BIOS INT 13
  1115.           entry point with no help from the user. Less compatible systems have
  1116.           presented more problems in the past, but current Registered versions
  1117.           of HDTEST are distributed on a disk whose boot sector has been
  1118.           modified to allow identification and use of the "real" entry point on
  1119.           almost any MS-DOS-compatible hardware. This modified boot sector will                                                                           ____
  1120.           be correctly duplicated if you back your distribution disk up by using
  1121.           the DOS "DISKCOPY" command - it will not be copied by a "COPY *.*"                                               ___                          
  1122.           command. This initially presented a significant potential problem for
  1123.           users of the Shareware version of the program, but the distribution
  1124.           packages of all current releases of HDTEST also contain a program
  1125.           
  1126.           
  1127.                                          Page 18 
  1128.            
  1129.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  1130.           
  1131.           
  1132.           (BOOTLOAD.COM) which will modify the boot sector of any removable                                                              ___          
  1133.           disk, allowing you to create a special pre-boot on the media of your
  1134.           choice. Further documentation for this program is to be found (as
  1135.           BOOTLOAD.DOC) in the distribution package.
  1136.  
  1137.           To use the special pre-boot, first insert your copy of the HDTEST
  1138.           distribution disk in the boot drive (normally drive A), then (re)boot
  1139.           your system as you normally do (either by switching it on or by
  1140.           pressing the <Ctrl>-<Alt>-<Del> combination or its equivalent for your
  1141.           hardware). After performing its self-test, the system's BIOS will load
  1142.           and pass control to the code on the boot sector of the floppy. On a
  1143.           normally FORMATTed floppy disk, this code attempts to locate the MS-
  1144.           DOS system files at the beginning of the disk's root directory and to
  1145.           load and execute them. The HDTEST boot disk will not load DOS (even if
  1146.           you SYS the disk) - it simply reads and reports on the contents of the
  1147.           INT 13 vector (which DOS has not yet had a chance to tamper with,
  1148.           since it has not been loaded) and conditionally transfers the vector
  1149.           to the INT 68 location. The INT 68 location is normally unused in MS-
  1150.           DOS systems - it is defined that way by IBM - and is usually loaded
  1151.           either with zeroes or with a pointer to some "do-nothing" code by the
  1152.           BIOS bootstrap. The HD programs use it for the "real" INT 13 vector,
  1153.           normally saving the original contents of the location on entry and
  1154.           restoring them on exit. This behavior is modified by specifying the /U
  1155.           switch on the command line. The HDTEST boot sector code will only
  1156.           transfer the "real" INT 13 BIOS entry point to the INT 68 location if
  1157.           the latter contains either zeroes or the same vector as INT 69. In the                              ______        __                                  
  1158.           latter case (since there is no point in having two "real" interrupt
  1159.           vectors pointing at the same place), it is assumed that both are
  1160.           pointing at "do-nothing" code. If the INT 68 vector is neither 0:0 nor                                                                 _______     ___
  1161.           the same as the INT 69 vector, the preboot code will leave it alone
  1162.           and report that the INT 13 vector was not transferred, otherwise it
  1163.           will confirm that the transfer has taken place - in any event, you
  1164.           will be given an opportunity to write down the vector and can then
  1165.           remove the disk and press a key to allow the boot process to complete.
  1166.           If you need to boot from a floppy disk, for some reason, a new,
  1167.           bootable, disk can be inserted before you press the key to continue.
  1168.  
  1169.           If the preboot reported that the INT 13 vector was successfully
  1170.           transferred, you should simply specify the /U flag on the HDTEST or
  1171.           HDCHEK command line, in addition to the "short" form of the /H flag                               ______________                                
  1172.           (if the BIOS ROM is at an unusual location for the class of machine).
  1173.           The requirement for the /H flag with unusual hardware allows the
  1174.           program to do some additional "reasonableness checking". Unless some
  1175.           other software interferes with it, the INT 68 vector will then
  1176.  
  1177.  
  1178.  
  1179.  
  1180.  
  1181.  
  1182.  
  1183.  
  1184.           
  1185.           
  1186.                                          Page 19 
  1187.            
  1188.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  1189.           
  1190.           
  1191.           continue to be set up correctly for use by the HD programs until the
  1192.           system is switched off or rebooted.
  1193.  
  1194.           If the preboot was not able to transfer the vector, or if you know
  1195.           that a device driver or resident program loaded by your DOS uses INT
  1196.           68, you should invoke the HD programs with the "long" form of the /H
  1197.           flag, specifying the full address displayed by the preboot. No error
  1198.           checking is attempted in this case - if you mistype the address, the
  1199.           first time the program attempts to access the disk, it will jump to a
  1200.           (effectively) random location in ROM, with potentially disastrous
  1201.           results. If it is feasible, use of the pre-boot disk and the /U flag
  1202.           is preferable (in terms of safety, if for no other reason) to that of
  1203.           the "long" form of /H.
  1204.  
  1205.           The following example may help to clarify matters. You have a clone
  1206.           system with a BIOS ROM location that is non-standard. The HDTEST boot
  1207.           disk reports that the INT 13 entry point is at E000:13AC, and that the
  1208.           vector has been successfully transferred. You may now run HDTEST with
  1209.           the command line:
  1210.  
  1211.           HDTEST C: A: /U /HE000                            ____
  1212.  
  1213.           You may also, now or later, with or without prior use of the pre-boot,                                      _______________                           
  1214.           run HDTEST with the command line:
  1215.  
  1216.           HDTEST C: A: /HE000:13AC                         _________
  1217.  
  1218.           Note that the /H flag is not needed with the /U flag if the segment                                   ___                                       
  1219.           address of the hard disk BIOS is the usual value for the system type                                                           ___________________
  1220.           (as determined by the processor). For a system based on an 8088, 8086,
  1221.           80188, or 80186 processor, this "usual" value is C800. For all other
  1222.           systems, the "usual" value is F000.
  1223.  
  1224.           It is important to note that the /Ex and /U (or /H) command line
  1225.           options are incompatible, since the former forces the HD programs to
  1226.           use the third-party INT 13 driver entry point, rather than the BIOS
  1227.           entry point. If you are unfortunate enough to have a system which has
  1228.           both a non-standard BIOS location and one or more partitions          ____                              ___                       
  1229.           controlled by SpeedStor or Disk Manager, you will need to use the /U
  1230.           or /H flags when testing the "vanilla" DOS partition(s) and the
  1231.           appropriate form of the /Ex flag when testing the "third-party"
  1232.           partitions.
  1233.  
  1234.           One further problem may be encountered - certain hard disk BIOSes do
  1235.           not exactly comply with IBM standards in dealing with disk accesses
  1236.           that cross track boundaries, and will produce frequent errors when
  1237.           such accesses are attempted. It was this "multi-track read" problem
  1238.           which resulted in a number of previously apparently 99.99% IBM-
  1239.           compatible systems failing to run IBM PC-DOS 3.3 (which was the first
  1240.           version of DOS actually to attempt such accesses). IBM issued a "fix"
  1241.           for this problem, in the form of a program which, when run on the
  1242.           "bad" system, creates a device driver which protects the BIOS from
  1243.           
  1244.           
  1245.                                          Page 20 
  1246.            
  1247.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  1248.           
  1249.           
  1250.           being asked to do something that it can't. This device driver does its
  1251.           job by intercepting INT 13, and will, of course, do nothing to help
  1252.           the HD programs if they are bypassing that interrupt. Use the /M flag
  1253.           with the HD programs if you have a system on which PC-DOS 3.3 or above
  1254.           will not run without being "fixed" as described. It forces the
  1255.           programs to split up the multi-track accesses into manageable chunks -
  1256.           this can be expected to cause a substantial slowing of the programs'
  1257.           operation.
  1258.  
  1259.  
  1260.                    USING THE HD PROGRAMS WITH SPEEDSTOR AND DISK MANAGER                   _____________________________________________________
  1261.  
  1262.           The HD programs will operate without problems under DOS 2.x through
  1263.           4.01 on almost all hard disks with up to 1024 cylinders, as well
  1264.           (usually) as on larger ESDI disks which use "sector translation" to
  1265.           appear to have less than this magic number of cylinders. An increasing
  1266.           number of disks now coming to market have more than this number of
  1267.           cylinders but do not have the ability to perform "sector translation".
  1268.           If their full extent is to be usable under DOS, these disks must be
  1269.           partitioned with the use of special non-DOS utilities (the two major
  1270.           contenders are SpeedStor and OnTrack's Disk Manager), and access to
  1271.           (at least) the "high" partitions requires a special driver to be
  1272.           loaded in CONFIG.SYS. In addition, many of those who used such third-
  1273.           party drivers to support partitions greater than 32 MB in extent under
  1274.           DOS versions prior to 4.0 on intermediate sized disks continue to use
  1275.           them for this purpose.
  1276.  
  1277.           Versions of the HD programs prior to V5.00 were only able to handle
  1278.           "third-party" partitions at the DOS level. The current version
  1279.           understands the partitioning schemes used by the SpeedStor (SS) and
  1280.           Disk Manager (DM) software, and can, if necessary, use the special
  1281.           drivers' INT 13 extensions to test the proprietary partitions as
  1282.           thoroughly as it does "normal" DOS partitions. In addition to using
  1283.           the /Ex command line flag (q.v.), it is necessary to load a special
  1284.           device driver, HDTESTDD.BIN, which is supplied with the HDTEST
  1285.           package, in CONFIG.SYS. The line: DEVICE=[drive:][path\]HDTESTDD.BIN
  1286.           should be added to CONFIG.SYS immediately after the line which loads                                        ______________________________________
  1287.           the partitioning software's driver. The HDTESTDD driver takes up only          __________________________________                                   
  1288.           128 bytes of memory, and the command to load it may be made a
  1289.           permanent part of your CONFIG.SYS - the driver does not intercept or
  1290.           chain into any interrupts and will have no effect on the normal
  1291.           functioning of your system. It does, however, allow the HD programs to
  1292.           locate and use the partitioning driver's INT 13 entry point, which
  1293.           they may not be able to obtain in any other way.
  1294.  
  1295.           Either SS or DM can be used to set up and format disks with one or
  1296.           (under DOS 3.3 and above) more normal DOS partitions, as well as, or
  1297.           sometimes instead of, one or more of their own proprietary ones. The
  1298.           /Ex command line switch should only be used for the proprietary                                         ____                            
  1299.           partitions - its use with normal DOS ones will slow the programs down
  1300.           somewhat and may make HDTEST less sensitive to minor problems.
  1301.  
  1302.           
  1303.           
  1304.                                          Page 21 
  1305.            
  1306.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  1307.           
  1308.           
  1309.           N.B. The SS or DM driver (SSTOR.SYS or DMDRVR.BIN) should always be          ____                                                               
  1310.           the first block device driver in CONFIG.SYS. Drivers for other block              _____                                                           
  1311.           devices such as RAMdisks, external floppy drives, tape drives, or CD-
  1312.           ROM drives should always follow both it and the HDTESTDD.BIN driver.
  1313.           The HD programs assume that the device names of any SS or DM
  1314.           partitions follow in alphabetical order immediately after those of any                                                  _________________             
  1315.           "normal" DOS floppy and hard disk partitions present. If any other
  1316.           devices are interposed, the HD programs will not be able to operate at
  1317.           anything but the DOS interrupt level.
  1318.  
  1319.           Reports that earlier versions of the HD programs could cause potential
  1320.           or actual data loss if run on disks with more than 1024 tracks appear
  1321.           to have resulted from attempts to use them on improperly partitioned                                                        ______________________
  1322.           drives. Problems with ESDI disks using sector translation were,
  1323.           however, eventually tracked down to a bug in the HD programs'
  1324.           initialization code which was causing the incorrect interpretation of
  1325.           partition table data in extended partitions, while problems with large
  1326.           disks using third-party partitioning drivers seem to have resulted
  1327.           from the incorrect designation of a partition ending above cylinder
  1328.           1023 as a DOS partition - a mistake which would have resulted in major
  1329.           problems from any attempt to access the area above track 1023. There                        ___                                                   
  1330.           now appears to be no evidence that earlier versions of HDTEST could
  1331.           damage data on properly partitioned disks of any size.                         ____________________                   
  1332.  
  1333.  
  1334.                            SPECIAL CONSIDERATIONS WITH SPEEDSTOR                           _____________________________________
  1335.  
  1336.           SpeedStor V6.0 and above uses a rather complex partition tree
  1337.           structure to support more than the 8 partitions per disk allowed by
  1338.           earlier versions of the software. SpeedStor also always names the
  1339.           partitions which it controls in alphabetical order as they appear on
  1340.           the physical disk, whether or not this is the order in which pointers
  1341.           to them are found while traversing the directory tree. There are,
  1342.           consequently, some circumstances under which the HD programs and
  1343.           SpeedStor may "disagree" about the order in which its partitions are
  1344.           named. This will generally cause HDTEST to "fall back" to DOS
  1345.           interrupt level when testing the disputed partitions. This problem
  1346.           will generally only be encountered when the "owner" of a partition is
  1347.           changed after a disk has been partitioned, and/or one or more
  1348.           partitions have been deleted and a larger number have been added in
  1349.           the middle of a disk. There is no "quick fix" for this problem. The
  1350.           best solution is to back up all the partitions on the "offending"
  1351.           device, and delete and recreate them "from scratch". This will ensure
  1352.           that SpeedStor and HDTEST agree on the order in which the partitions
  1353.           are named.
  1354.  
  1355.  
  1356.                                   DEALING WITH BAD CLUSTERS                                  _________________________
  1357.  
  1358.           It is not unusual for a new hard disk to have a small, constant,                                                          _____  ________ 
  1359.           number of bad clusters. IBM's quality control standards allow, for
  1360.           example, 5% of the surface area of a disk to be bad (!). These pre-
  1361.           
  1362.           
  1363.                                          Page 22 
  1364.            
  1365.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  1366.           
  1367.           
  1368.           existing bad clusters, which correspond to imperfections in the
  1369.           magnetic coating on the disk, will normally be detected by the
  1370.           manufacturer's routine tests. Their locations will appear on the
  1371.           "badspot list", which comes with the drive, and the whole track which
  1372.           contains the defect will be marked as bad during low-level formatting.
  1373.           The marked bad sectors will be detected by the DOS FORMAT program,
  1374.           which will mark the relevant clusters as bad, and HDTEST will report
  1375.           them as "already marked as bad". This should not be regarded as
  1376.           evidence of any real problem with the disk, although some suppliers
  1377.           (not including IBM) will replace such disks under warranty if pressed           ___                                                                 
  1378.           to do so. It is also not unusual for a disk to develop a few more                                                                   ___     
  1379.           defects as it ages. When these do develop, they should also
  1380.           subsequently be constant in size and position, and will be reported as
  1381.           "already marked as bad" by HDTEST on runs subsequent to that during
  1382.           which they are first found. The occasional appearance (and subsequent                                          __________                           
  1383.           persistence) of a new bad cluster is, therefore, not necessarily
  1384.           evidence of serious trouble developing.  However, if more than one or
  1385.           two new bad clusters are reported by HDTEST, and especially if two
  1386.           consecutive runs (or passes, if the /R flag is set) of HDTEST report
  1387.           different bad clusters, there is a good chance that the hard disk or          _________                                                           
  1388.           controller is developing a serious problem - the disk should be backed
  1389.           up immediately and the disk and/or controller sent for repair at the
  1390.           earliest opportunity.
  1391.  
  1392.           New bad clusters in the data area are automatically mapped out by
  1393.           HDTEST, and no further action is necessary. Bad sectors in the DOS
  1394.           area can be handled in two ways:
  1395.  
  1396.           1) If you are able to do a low-level format on your hard disk (most                                     _________                               
  1397.           makers of "add-on" hard disks supply a method of doing this, either in
  1398.           the form of a short program, or by giving instructions for running a
  1399.           program in the ROM BIOS from DEBUG), back up the entire hard disk                                                           ______          
  1400.           (including any non-DOS partitions), run the low-level format, use
  1401.           FDISK to repartition the disk, and then run the DOS FORMAT program. If
  1402.           HDTEST now reports no errors in the DOS area you can restore all your
  1403.           files and continue to use the disk. You should, however, use HDTEST to
  1404.           test (at least) the DOS area fairly frequently for a month or so to be
  1405.           sure that the problems are not going to recur.
  1406.  
  1407.           2) If you do not have the means to do a low-level format, or if you
  1408.           follow the above instructions and HDTEST continues to report errors in
  1409.           the DOS area, your only other choice is to back up the DOS partition,
  1410.           reconfigure the disk with FDISK so that the new DOS partition starts
  1411.           above the bad area, reFORMAT it, and restore all of the old files to
  1412.           the new DOS partition (which will unavoidably be a little smaller than
  1413.           the old).
  1414.  
  1415.           If the hard disk's boot/partition sector (track 0, Head 0, sector 1)
  1416.           becomes bad, the disk is useless and must be replaced. This sector is
  1417.           only subjected to read/write testing if the /B flag is specified on                            __________                                       
  1418.           the command line, so any reported errors (in sector -1) during normal                                                              __               
  1419.           testing represent a problem reading the sector and are likely to be                                      _______                                
  1420.           
  1421.           
  1422.                                          Page 23 
  1423.            
  1424.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  1425.           
  1426.           
  1427.           significant. Problems encountered during read/write testing of this
  1428.           sector do not always indicate a significant problem - certain                    ___                                                
  1429.           controller cards may not allow test patterns to be written to it,
  1430.           resulting in a report of multiple errors on read/write testing.
  1431.           Consequently, if multiple errors are reported on read/write testing of
  1432.           the boot/partition sector, but read-only testing proceeds without
  1433.           problems and the rest of the disk seems to be OK, there is probably no
  1434.           cause for concern.
  1435.  
  1436.  
  1437.                               RUNNING HDTEST FROM A .BAT FILE                              _______________________________
  1438.  
  1439.           Versions of HDTEST from V4.75 can be run from a .BAT file (e.g. for
  1440.           unattended testing of multiple disks) without the user losing the
  1441.           ability to "escape" cleanly from the program. The /Y flag also allows
  1442.           the user to specify a maximum number of new bad clusters for each disk
  1443.           to be remapped "automatically", so that the .BAT file will normally
  1444.           just keep going but will pause and wait for input if something
  1445.           terrible seems to have happened to a disk. In order to run HDTEST from
  1446.           a .BAT file, it is necessary to prepare both the .BAT file with your                                                  ____                        
  1447.           usual HDTEST command lines, generally including the /Y and /N flags,
  1448.           and a second ASCII file containing the answers to HDTEST's initial          ___                                                               
  1449.           questions, one per line. DOS's input redirection ("<") command is used
  1450.           to "feed" these answers to HDTEST. If the "answer" file is called
  1451.           (e.g.) ANSWERS.TXT, each line in the .BAT file will look like:
  1452.  
  1453.               HDTEST dev1 dev2 /opt1 /opt2 <ANSWERS.TXT                                           ____________
  1454.  
  1455.           If you do not wish to read/write test the DOS area of the disk, your
  1456.           answer file can consist of three blank lines. If you do wish to                                                               __        
  1457.           read/write test the DOS area, the first line of the answer file can be
  1458.           blank, the next two must start with a "y" and the fourth can be blank.                          ___                                                   
  1459.           In order to allow HDTEST to be interrupted from the keyboard, if
  1460.           necessary, the program terminates input redirection before starting
  1461.           testing the disk, so anything in the answer file after the answers to                                                           _____               
  1462.           HDTEST's initial questions will be ignored.
  1463.  
  1464.           On exit, HDTEST now returns a meaningful ERRORLEVEL, which can be
  1465.           tested from a .BAT file by means of DOS's "IF ERRORLEVEL" syntax.
  1466.           Versions of the program prior to V4.81 returned an ERRORLEVEL of 1 on
  1467.           aborts and 0 otherwise - HDCHEK still does this. The current version
  1468.           of HDTEST normally returns an ERRORLEVEL equal to the number of new
  1469.           bad clusters found. On aborts it returns 254, and, if deliberately
  1470.           terminated by the user (either by answering "N" to the last question
  1471.           in the introductory dialogue or by pressing and confirming <Esc>
  1472.           during testing), it returns 255.
  1473.  
  1474.           You should not normally use HDTEST's incremental testing functionality
  1475.           (see "Incremental Disk Testing" section) when running the program from
  1476.           a .BAT file - if HDTEST finds HDTESTED.MP0 in the root directory while
  1477.           being run from a .BAT file, it will not ask whether or not to use the
  1478.           information in it. It will simply use it if the file is less than 14
  1479.           
  1480.           
  1481.                                          Page 24 
  1482.            
  1483.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  1484.           
  1485.           
  1486.           days old, and not otherwise (these would be the default responses if
  1487.           the program prompted for them).
  1488.  
  1489.           Note that this application of HDTEST is really intended for advanced
  1490.           users, and I am aware that this description is somewhat cursory - more
  1491.           help in using it can, if necessary, be obtained directly from me.
  1492.  
  1493.  
  1494.                             BUGS AND OTHER UNPLEASANT SUBJECTS                            __________________________________
  1495.  
  1496.           Although, like all programmers, I like to think that my product is
  1497.           perfect, it is possible that there are a few bugs lurking in the
  1498.           depths of the program, and likely that some combination of software
  1499.           and hardware exists which HDTEST cannot figure out and/or cope with.
  1500.           If you think you have found a bug and/or if you cannot get either of
  1501.           the programs to work on your system, do the following:
  1502.  
  1503.           1) Reread this documentation! Make sure that you are doing exactly
  1504.           what the documentation says to do. Make sure (if you are testing a
  1505.           drive with removable media) that the media is not write-protected.
  1506.  
  1507.           2) Boot your system from a "virgin" DOS disk - preferably a copy of
  1508.           your DOS distribution disk with only any additional drivers necessary
  1509.           to support the partitioning of your hard disk (and HDTESTDD.BIN) added
  1510.           in CONFIG.SYS - and try to run the HD programs again. If they run in
  1511.           this environment but not in your normal DOS environment, try
  1512.           reconstructing the system under which they failed by adding things one
  1513.           by one until the problem recurs. If you find a specific piece of
  1514.           software which causes the trouble, let me know about the
  1515.           incompatibility.
  1516.  
  1517.           3) If the above approaches do not help, or if HDCHEK runs but HDTEST
  1518.           bombs (the reverse should only happen if HDTEST aborts with an
  1519.           "insufficient memory" error), send me as detailed a description of the
  1520.           problem as possible and I will do my best to diagnose and fix it. A
  1521.           bug report should always include a full description of the system                            ______                                         
  1522.           being used (hardware and software), as well as a copy of the output                               ___                                           
  1523.           from a run of HDCHEK.
  1524.  
  1525.           I can be contacted by U.S. mail at the address given earlier in the
  1526.           documentation, by BIXMail to pfletcher, or by Compuserve EMail to
  1527.           72255,305.
  1528.  
  1529.  
  1530.                               CHANGES FROM PREVIOUS VERSIONS                              ______________________________
  1531.  
  1532.           The first version of the HD programs actually released (not including
  1533.           beta-test versions) was V2.60. The programs have grown and developed
  1534.           gradually, for the most part, but the releases listed below have
  1535.           constituted the most significant "watersheds" - features added and
  1536.           changes made between the listed releases are treated here as if first                       _______                                                 
  1537.           included in the next listed release, so some individuals for whom this                          ____                                                  
  1538.           
  1539.           
  1540.                                          Page 25 
  1541.            
  1542.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  1543.           
  1544.           
  1545.           is an upgrade may have packages with some, but not all, of the
  1546.           features listed for a given release. Note that the V4.45 Shareware
  1547.           version of the program is not listed here - it was identical to V4.41
  1548.           except that it included the "fix" for a deficiency which was corrected
  1549.           at V4.70 in the Registered version. Similarly, the V4.98 Shareware
  1550.           version contains all the logic error "fixes" documented for V5.20,
  1551.           together with fixes for one or two other bugs and deficiencies
  1552.           discovered during work on that version. Unless otherwise noted, both
  1553.           programs were affected by the listed changes.
  1554.  
  1555.  
  1556.           Version 5.35a (this version)          _____________               
  1557.  
  1558.           1) Bugs in code supporting "incremental" disk testing identified and
  1559.           fixed (HDTEST only).
  1560.  
  1561.  
  1562.           Version 5.35          ____________
  1563.  
  1564.           1) Support for "incremental" disk testing added.
  1565.  
  1566.           2) Support for MS/PC DOS 5.0 added.
  1567.  
  1568.           3) Limited LIM 4.0 support added (up to 64 KB of LIM memory will be
  1569.           used, if present, sparing the equivalent amount of normal DOS memory).
  1570.  
  1571.           4) Directory tree buffering scheme redesigned to allow more files per
  1572.           partition.
  1573.  
  1574.           5) Miscellaneous minor inaccuracies in the text of error messages
  1575.           corrected.
  1576.  
  1577.  
  1578.           Version 5.23          ____________
  1579.  
  1580.           1) Option to proceed after bad 8088 chip identified added.
  1581.  
  1582.           2) Minor changes in error messages.
  1583.  
  1584.           3) Rearranged code and link order to reduce program .EXE size.
  1585.  
  1586.  
  1587.           Version 5.20          ____________
  1588.  
  1589.           1) Support for "extended" INT 13 used by Disk Manager and SpeedStor
  1590.           added.
  1591.  
  1592.           2) Support for SpeedStor and Disk Manager large partitions under DOS
  1593.           3.xx added.
  1594.  
  1595.           3) Ability to abort HDTEST cleanly by entering <Ctrl-C> added.
  1596.  
  1597.           
  1598.           
  1599.                                          Page 26 
  1600.            
  1601.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  1602.           
  1603.           
  1604.           4) Bug causing erroneous report of "more than 1024 tracks" on failure
  1605.           to access disk via BIOS fixed.
  1606.  
  1607.           5) Bug causing system to hang at unexpected "Press any key to
  1608.           continue...." prompt if run from .BAT file fixed.
  1609.  
  1610.           6) Logic errors causing improper "parsing" of long extended partition
  1611.           chains and chains containing DM and SpeedStor partitions corrected.
  1612.  
  1613.  
  1614.           Version 4.95          ____________
  1615.  
  1616.           1) Added code to prevent undetected "wrap-around" when using existing
  1617.           INT 13 on a disk with more than 1024 cylinders.
  1618.  
  1619.           2) Deficiency allowing "queueing" of keystrokes in typeahead buffer
  1620.           fixed. <Esc> now produces (almost) immediate response even if other
  1621.           key(s) have been pressed first (HDTEST).
  1622.  
  1623.           3) Copyright screen displayed for minimum of 2 seconds (may be longer
  1624.           if program is being run on a large device).
  1625.  
  1626.           4) Previous restriction on testable FAT size (was 64 Kb) removed.
  1627.  
  1628.           5) /V option added to bypass "virtual mode" prohibition.
  1629.  
  1630.  
  1631.           Version 4.84          ____________
  1632.  
  1633.           1) Bug causing the programs to fail if a subdirectory were physically
  1634.           located beyond the 32 Mb boundary on a large (> 32 Mb) device located
  1635.           and corrected.
  1636.  
  1637.           2) Deficiency causing "fallback" to DOS interrupt level under some
  1638.           circumstances when attempting to test "extended devices" on a second
  1639.           physical hard drive fixed. The Shareware V4.45 also included this
  1640.           "fix".
  1641.  
  1642.           3) Log file specification capabilities enhanced (HDTEST).
  1643.  
  1644.           4) DOS 4.0 support added (including BIOS-level access to large
  1645.           partitions).
  1646.  
  1647.           5) Meaningful ERRORLEVEL returned on exit (see "Running HDTEST from a
  1648.           .BAT file) (HDTEST).
  1649.  
  1650.           6) Minor improvements made to memory allocation algorithms.
  1651.  
  1652.           7) Minor changes made to final screen & file output format (HDTEST).
  1653.  
  1654.           8) Minor change to reporting of initialization errors (HDCHEK).
  1655.  
  1656.           
  1657.           
  1658.                                          Page 27 
  1659.            
  1660.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  1661.           
  1662.           
  1663.           9) Fully automatic setting of default ROM BIOS location by CPU type.
  1664.           Meaning of and requirement for /A flag modified.
  1665.  
  1666.           10) Support for large devices under Compaq DOS 3.31 added (see
  1667.           description of /C flag).
  1668.  
  1669.           11) /Y flag and .BAT file support added (HDTEST).
  1670.  
  1671.           12) /G option added (HDTEST).
  1672.  
  1673.           13) /X option added (HDTEST).
  1674.  
  1675.  
  1676.           Version 4.54          ____________
  1677.  
  1678.           1) Deficiency in CPU recognition code (which caused fast AT clones
  1679.           sometimes not to appear to be ATs) fixed.                    ___                            
  1680.  
  1681.           2) ANSI.SYS requirement removed.
  1682.  
  1683.           3) Semi-automatic CPU recognition added.
  1684.  
  1685.           4) Pre-boot functionality, /M option, /U option, and extended
  1686.           (segment:offset) form of /H option added.
  1687.  
  1688.  
  1689.           Version 4.41          ____________
  1690.  
  1691.           1) Deficiency (introduced at V4.00) causing HDCHEK to issue an
  1692.           incorrect error report on an abort resulting from a FAT comparison
  1693.           error corrected.
  1694.  
  1695.           2) Minor deficiency, causing HDTEST to create an empty log file on the
  1696.           specified device when both a log device and the /P option were
  1697.           specified, corrected.
  1698.  
  1699.           3) Work-around for hardware multi-sector read ECC problem (see
  1700.           Appendix B) added (HDTEST).
  1701.  
  1702.           4) Support for small (<= 10 Mb) hard disks patched to have small
  1703.           clusters and 16-bit FATs added.
  1704.  
  1705.           5) Requirement that command line option flags be separated by one or
  1706.           more spaces or tabs removed.
  1707.  
  1708.           6) /R option added (to HDTEST) for multi-pass disk testing.
  1709.  
  1710.  
  1711.  
  1712.  
  1713.  
  1714.  
  1715.           
  1716.           
  1717.                                          Page 28 
  1718.            
  1719.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  1720.           
  1721.           
  1722.           Version 4.30          ____________
  1723.  
  1724.           1) Support for BIOS-level access to DOS 3.3 extended partitions added.
  1725.  
  1726.           2) /Z option added (to HDTEST) to control remapping of unreadable
  1727.           sectors in bad clusters.
  1728.  
  1729.  
  1730.           Version 4.10          ____________
  1731.  
  1732.           1) Assorted minor changes made to screen displays.
  1733.  
  1734.           2) /C option added to allow the programs to be used on some non-IBM
  1735.           compatible MS-DOS systems.
  1736.  
  1737.           3) /D option redefined - old /D option became new /I option.
  1738.  
  1739.           4) /F option added (to HDTEST).
  1740.  
  1741.           5) "Short" form of /H option added.
  1742.  
  1743.  
  1744.           Version 3.13          ____________
  1745.  
  1746.           1) Assorted minor bugs and deficiencies in error reporting and
  1747.           termination routines fixed (HDTEST).
  1748.  
  1749.           2) Minor bug affecting reporting of multiple corrected ECC errors
  1750.           fixed (HDTEST).
  1751.  
  1752.           3) Disk reset added before retry on all errors (HDTEST).
  1753.  
  1754.           4) Absolute limit on number of files and directories on device
  1755.           removed.
  1756.  
  1757.           5) Display of total sector/cluster count during testing added
  1758.           (HDTEST).
  1759.  
  1760.           6) /A option added.
  1761.  
  1762.           7) /B option added (HDTEST).
  1763.  
  1764.  
  1765.           Version 2.73          ____________
  1766.  
  1767.           1) Bug (in V2.60) which could cause bad termination and possible
  1768.           subdirectory inconsistencies if a sector which was not in use was
  1769.           found to be bad, fixed (HDTEST).
  1770.  
  1771.           2) Bug (in V2.70) which caused HDTEST to enter a terminal input loop
  1772.           if ANSI.SYS was not loaded and <Esc> was entered to abort it, fixed.
  1773.  
  1774.           
  1775.           
  1776.                                          Page 29 
  1777.            
  1778.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  1779.           
  1780.           
  1781.           3) Minor bug in V2.60 (which resulted in a failed directory scan if
  1782.           the program was run on a write-protected device) fixed.
  1783.  
  1784.           4) Internal changes made to avoid interference with expanded memory
  1785.           device handlers.
  1786.  
  1787.           5) Ability to update disk after HDTEST terminated by user (typing
  1788.           <Esc>) added.
  1789.  
  1790.           6) /S option to start checking occupied clusters at a given cluster
  1791.           number added (HDTEST).
  1792.  
  1793.  
  1794.  
  1795.  
  1796.  
  1797.  
  1798.  
  1799.  
  1800.  
  1801.  
  1802.  
  1803.  
  1804.  
  1805.  
  1806.  
  1807.  
  1808.  
  1809.  
  1810.  
  1811.  
  1812.  
  1813.  
  1814.  
  1815.  
  1816.  
  1817.  
  1818.  
  1819.  
  1820.  
  1821.  
  1822.  
  1823.  
  1824.  
  1825.  
  1826.  
  1827.  
  1828.  
  1829.  
  1830.  
  1831.  
  1832.  
  1833.           
  1834.           
  1835.                                          Page 30 
  1836.            
  1837.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  1838.           
  1839.           
  1840.                            APPENDIX A - SUMMARY OF FLAG SETTINGS                           _____________________________________
  1841.  
  1842.           /A(T) - used to tell the HD program that it is being run on an IBM AT
  1843.           (HDCHEK and HDTEST). /A is not equivalent to /HF000.
  1844.  
  1845.           /B(oot/Partition sector test) - used to include the hard disk
  1846.           boot/partition sector in the DOS area for the purposes of read/write
  1847.           testing (HDTEST only).
  1848.  
  1849.           /C(lone BIOS)n - used in systems which do not support the IBM BIOS's
  1850.           INT 11 "equipment determination" BIOS function (e.g. the Tandy 2000).
  1851.           The parameter ("n") is the number of floppy drives attached to the
  1852.           system, which is otherwise determined automatically (HDCHEK and
  1853.           HDTEST).
  1854.  
  1855.           /CQ (Compaq) - used to indicate that the program is running on a
  1856.           Compaq system. If DOS 3.31 (or above) is in use, large (> 32 Mb)
  1857.           devices are supported (HDCHEK and HDTEST).
  1858.  
  1859.           /E(xtended INT 13)x - allows testing of "proprietary" partitions
  1860.           created by SpeedStor and Disk Manager partitioning software, and the
  1861.           use of the "extended" INT 13 definitions which permit SpeedStor and
  1862.           Disk Manager to support disks with more than 1024 cylinders. Use /ES
  1863.           to use SpeedStor extensions and /ED for Disk Manager extensions.
  1864.  
  1865.           /D(OS interrupts) forces the program to use only DOS interrupts
  1866.           (INT 25 and INT 26) for access to the target device. May not be
  1867.           combined with the /I, /H, or /U flag (HDCHEK and HDTEST).
  1868.  
  1869.           /F(ast mode) limits read/write testing to the use of two patterns only
  1870.           (HDTEST only).
  1871.  
  1872.           /G(ive error details) allows the physical disk location of bad sectors
  1873.           to be identified (HDTEST only).
  1874.  
  1875.           /H(ex BIOS address)nnnn[:nnnn] - used to tell the HD programs that the
  1876.           ROM BIOS of the device being tested is located at nnnn, which is
  1877.           interpreted as a Hexadecimal segment address, rather than at the (CPU-
  1878.           dependent) default. The extended (segment:offset) form of the command
  1879.           is used to force the programs to use the given address as the INT 13
  1880.           entry point (HDCHEK and HDTEST).
  1881.  
  1882.           /I(nterrupt 13) - forces the program to use the existing INT 13
  1883.           vector.  This is the default under DOS 2.x. May not be combined with
  1884.           the /D, /H, or /U flag (HDCHEK and HDTEST).
  1885.  
  1886.           /M(ulti-track read problem) - bypasses the multi-track read problem
  1887.           which also prevents certain otherwise IBM-compatible clones from
  1888.           running PC-DOS 3.3 (HDCHEK and HDTEST).
  1889.  
  1890.           /N(o Query) - disables the individual prompts for confirmation which
  1891.           the program normally issues before remapping "special" clusters - does
  1892.           
  1893.           
  1894.                                          Page 31 
  1895.            
  1896.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  1897.           
  1898.           
  1899.           not prevent the program from prompting for confirmation before          ___                                                           
  1900.           updating the disk (HDTEST only).
  1901.  
  1902.           /P(rint) - causes the log file to be directed to the PRN device
  1903.           (HDTEST only).
  1904.  
  1905.           /R(epeat)n - causes HDTEST to perform n complete testing cycles (or to
  1906.           continue until interrupted for n=0) (HDTEST only).
  1907.  
  1908.           /S(tart from)nnnnn - causes HDTEST to start testing occupied clusters                                                              ________         
  1909.           at cluster number nnnnn (expressed as a decimal number) (HDTEST only).
  1910.  
  1911.           /U(se existing INT 68 vector) - causes the HD programs to use the
  1912.           existing INT 68 vector as the INT 13 entry point (HDCHEK and HDTEST).                   ______                                                      
  1913.  
  1914.           /V(irtual mode) - bypasses normal prohibition on running program if
  1915.           80286 or better CPU is operating in "virtual mode". Allows use with
  1916.           QEMM-386 and 386^Max.
  1917.  
  1918.           /X(clude marked bad sectors) - causes HDTEST to report on but not
  1919.           retest clusters that are already marked as bad (HDTEST only).
  1920.  
  1921.           /Y(es, please remap)n - allows HDTEST to update the disk by remapping
  1922.           up to n new bad sectors without prompting for confirmation (HDTEST                                  _______                                   
  1923.           only).
  1924.  
  1925.           /Z(ap bad sectors)n - controls remapping of unreadable sectors in bad
  1926.           clusters (HDTEST only) - n may have one of the following values:
  1927.               0 - Remap clusters with any unreadable sectors to all NULLs
  1928.               1 (default) - Remap only actual unreadable sectors to NULLs
  1929.               2 - Transfer all data read to the new cluster
  1930.  
  1931.  
  1932.  
  1933.  
  1934.  
  1935.  
  1936.  
  1937.  
  1938.  
  1939.  
  1940.  
  1941.  
  1942.  
  1943.  
  1944.  
  1945.  
  1946.  
  1947.  
  1948.  
  1949.  
  1950.  
  1951.           
  1952.           
  1953.                                          Page 32 
  1954.            
  1955.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  1956.           
  1957.           
  1958.                              APPENDIX B - A HARDWARE TUTORIAL                             ________________________________
  1959.  
  1960.           Users of earlier versions of this software repeatedly requested that I
  1961.           provide a more detailed explanation of the significance of some of the
  1962.           error messages displayed by HDTEST when it encounters a bad sector or
  1963.           cluster on the disk. It is not possible to do this without assuming
  1964.           (or imparting) a more detailed understanding of the "nitty-gritty"
  1965.           details of data storage on hard and floppy disks than most people want
  1966.           or need, let alone possess. This Appendix is not, therefore, "required
  1967.           reading" for the safe or effective use of the HD programs. It is
  1968.           intended as a tutorial for those who would like to understand some-
  1969.           thing more of what is really going on on their hard or floppy disk                                ______                                      
  1970.           drive when the little red light comes on.
  1971.  
  1972.           For the purposes of what follows, it is (fortunately) not necessary to
  1973.           know or understand exactly how changes in magnetic flux on the surface
  1974.           of a hard (or floppy) disk are translated into binary data, or vice
  1975.           versa. That could be the subject of another long dissertation. I will
  1976.           simply take for granted that binary data, conceptually organized into
  1977.           8-bit bytes, can be read and written by the disk drive hardware under
  1978.           the command of its controller (which usually resides on a separate
  1979.           card plugged into one of the computer's expansion slots). I will be
  1980.           describing how blocks of data are physically arranged on a disk and
  1981.           how the disk controller goes about ensuring that the data it reads has
  1982.           not been corrupted since it was written.
  1983.  
  1984.           I propose to start off by referring to some of the error-detection and
  1985.           error-correction techniques and procedures that are applied to data
  1986.           stored on magnetic media. These techniques and procedures are
  1987.           necessary because, although magnetic media are very reliable and the
  1988.           technology of recording and playback is well understood, there always
  1989.           remains the possibility that a defect in the medium or some other
  1990.           intercurrent problem may cause the sequence of bytes read back from a
  1991.           disk or tape to be something other than a perfect duplicate of the
  1992.           sequence that was stored. If a single copy of the raw data were all
  1993.           that were recorded, there would be no way of immediately detecting
  1994.           (let alone correcting) such an error. It might be brought to light
  1995.           when the file that was changed caused problems when it is used by or
  1996.           executed as a program, but it might not become apparent until it had
  1997.           propagated itself through and caused problems or errors in multiple
  1998.           other programs or files. This would clearly be an unacceptable state
  1999.           of affairs. In order to prevent this from occurring, then, there
  2000.           should be some means of checking data which is read in from storage
  2001.           for errors, and/or (preferably) of correcting any errors which may
  2002.           have occurred before any use is made of the data.                        ______                             
  2003.  
  2004.           Although error checking and/or correction can (and sometimes does)
  2005.           take place at any level from that of the application program down to
  2006.           that of the device controller, I am only going to describe the means
  2007.           that are used by hard and floppy disk controllers. When a block of
  2008.           data is passed to the controller to be written to the disk, a series
  2009.           of arithmetical operations is performed in sequence on all the bytes
  2010.           
  2011.           
  2012.                                          Page 33 
  2013.            
  2014.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  2015.           
  2016.           
  2017.           in the block, to produce a 2-byte (for diskettes) or multi-byte (for
  2018.           hard drives) code. The diskette controller implements what is known as
  2019.           a cyclic redundancy check (CRC) algorithm, which is optimized to allow
  2020.           detection of all single bit errors and many longer error bursts (it is          _________                                                             
  2021.           reasonable to assume that errors will most probably either affect a
  2022.           single bit at random or, if they result from media defects, a number
  2023.           of adjacent bits). The longer (at least 32-bit) error correcting code
  2024.           (ECC) calculated by a hard disk controller gives enough information to
  2025.           allow detection and correction of, at least, all single bit errors and                          ______________                                        
  2026.           detection of most likely longer error bursts. The CRC or ECC is saved
  2027.           on disk with the data and is read back in by the controller when the
  2028.           data is read. The controller then compares the saved CRC or ECC with
  2029.           one newly calculated from the data. If the two are identical, the data
  2030.           is assumed to be valid and a successful read is signalled. If there is
  2031.           a discrepancy, a diskette controller always returns the data with a
  2032.           "CRC error", since the CRC code does not contain enough information to
  2033.           allow the incorrect bit or bits to be identified. On a hard disk, if
  2034.           the ECC comparison suggests a correctable error, it will be corrected,
  2035.           and the read call will return with a "Corrected ECC Error" code but
  2036.           with (presumably) valid data in the transfer buffer. If a more
  2037.           extensive error is detected, on the other hand, the call returns with
  2038.           a "Uncorrectable ECC Error" code (which is the same as the CRC error
  2039.           code).
  2040.  
  2041.           The 32-bit ECC used by IBM and many compatible disk manufacturers
  2042.           allows correction of single-bit errors only. Manufacturers of other,                                                 ____                         
  2043.           usually more expensive, controllers use longer and more complex ECCs,
  2044.           to allow the correction of some multi-bit errors, but the necessity to
  2045.           minimize the time taken to calculate the ECC (which is part of "access
  2046.           time") sets tight limits on how complex it can be. ECC error
  2047.           correction is unfortunately not infallible. It is possible for a                                      ___                                 
  2048.           complex, uncorrectable error to result in the same ECC disparity as a                   __                                                          
  2049.           different, correctable, error, so that invalid "corrected" data can be                                                                          ______
  2050.           returned. The longer and more complex the ECC, the less likely this
  2051.           becomes, but there is no way of completely avoiding this ambiguity,
  2052.           short of keeping multiple copies of the data on the disk. In addition,
  2053.           some hard disk controllers* apparently abort with the "corrected ECC
  2054.           error" code immediately on encountering a sector containing such an                      ___________                                            
  2055.           error, even if it is not the last sector in the block specified by a                               ___                                            
  2056.           (multi-sector) read request. This non-intuitive (to say the least of
  2057.           it) behavior can combine with DOS >= 3.x's habit of ignoring corrected                                                              ________          
  2058.           ECC errors to result in apparently inexplicable disk-related problems,
  2059.           up to and including system crashes (if the file in which the problem
  2060.           occurred contained executable code). This hardware deficiency may be
  2061.           related to the problems which have plagued users of DOS 3.3 on some
  2062.           (previously) apparently IBM-compatible non-IBM hardware, since these
  2063.           also result from (similar but distinct) deficiencies in the clones'
  2064.  
  2065.           _____________________________________________________________________
  2066.  
  2067.           * This behavior is known to occur with some early Western Digital
  2068.           controllers (1002A-WX1, 1002S-WX2) but it may occur with others, too.
  2069.           
  2070.           
  2071.                                          Page 34 
  2072.            
  2073.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  2074.           
  2075.           
  2076.           handling of multi-sector disk reads. Prior to V4.36, HDTEST did retry                                                                      ___      
  2077.           corrected ECC errors which were reported on the first read of a
  2078.           cluster, but would eventually (if the corrected error persisted)
  2079.           accept the data read as valid and copy and remap it to a "good"
  2080.           cluster. This could cause trouble if the controller had the "immediate
  2081.           abort on corrected ECC error" problem described above and the ECC                                                                ___        
  2082.           error were not in the last sector of the cluster, since the sectors
  2083.           after the "bad" one would not have been read, and would be lost
  2084.           (actually replaced by the corresponding sectors from the previous                                                                   ________
  2085.           cluster read) after remapping. On a machine with this problem, DOS
  2086.           would not, of course, have done any better than the earlier versions
  2087.           of HDTEST at reading the bad cluster, and HDTEST at least warned you
  2088.           that there was a problem, but the behavior described was certainly not
  2089.           ideal. From V4.36, HDTEST rereads clusters in which a persistent
  2090.           corrected ECC error is reported on the initial read sector by sector,                                                              ________________ 
  2091.           to ensure that all the data in the cluster is transferred when it is                         ___                                                  
  2092.           remapped. In most cases (as long as the ECC error was really                                                                ______
  2093.           correctable), this will save the cluster (and the file of which it is
  2094.           a part) intact.
  2095.  
  2096.           DOS allows the programmer and/or computer user to think of and deal
  2097.           with disk data in terms of files, lines, and/or records, but data is
  2098.           always moved between a disk and memory a sector at a time. Any disk
  2099.           read or write request passed to DOS eventually gets translated into a
  2100.           command to read or write one or more sectors on the disk, commencing
  2101.           at a specified head, track, and sector. A floppy disk may have either
  2102.           one or two usable surfaces, corresponding to the top and bottom of the                            ________                                            
  2103.           disk. A hard disk usually has at least two surfaces, and may have
  2104.           more, since multiple physical "platters" are frequently incorporated
  2105.           in a single device. Each surface is normally accessed by and
  2106.           corresponds to a single read/write head, which moves radially across                                             ____                             
  2107.           it, although one surface on newer disks is often reserved for "servo"
  2108.           tracks, which are written with a special pattern that allows the
  2109.           controller to ensure that the read/write heads are kept exactly
  2110.           aligned with the data tracks. For a single device, the (data) heads
  2111.           are, by convention, numbered sequentially from zero up to one less
  2112.           than the total number present. Each surface is further divided into a
  2113.           number of circumferential tracks (or cylinders) and each track is                                    ______     _________                   
  2114.           divided into a number of sectors. Again by convention, the tracks on                                   _______                                    
  2115.           each surface are also numbered sequentially from zero, with track zero
  2116.           being the outermost track. The sectors on each track are normally
  2117.           numbered from one to a number corresponding to the total number of                        ___                                                 
  2118.           sectors on the track, but adjacent sectors do not normally have                                                        ___              
  2119.           consecutive sector numbers. A typical arrangement of the seventeen
  2120.           sectors on a single track of an XT hard disk, for example, would be as
  2121.           follows: 1,8,15,5,12,2,9,16,6,13,3,10,17,7,14,4,11. This "inter-                                                                    ______
  2122.           leaving" of sectors helps to make multi-sector disk reads and writes          _______                                                             
  2123.           more efficient. The controller requires a finite time to process the
  2124.           data from one sector before it can start reading (or writing) the
  2125.           next. During this time, of course, the disk continues to rotate and
  2126.           one or more of the sectors which physically "follow" the one that was
  2127.           last accessed pass under the read/write head unread. Ideally, the
  2128.           
  2129.           
  2130.                                          Page 35 
  2131.            
  2132.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  2133.           
  2134.           
  2135.           interleave (number of physical sectors separating consecutively
  2136.           numbered sectors) should be such that the next sector is just about to
  2137.           come under the read-write head when the controller is free to deal
  2138.           with it, but, because this time is not exactly predictable, it is
  2139.           better to be too conservative (as IBM usually is) and make it one or
  2140.           two sectors longer than necessary than to be too optimistic. Too small
  2141.           an interleave value is very undesirable, because it results in the
  2142.           controller having to wait almost a complete disk rotation time for
  2143.           each sector it misses to come round again.
  2144.  
  2145.           At the beginning of each disk sector is an address mark, a short,                                                     ____________          
  2146.           recognizable (to the controller) bit sequence containing the track and
  2147.           sector number. The process of writing the address marks for each
  2148.           sector on a disk is known as "low-level" or "sector" formatting. The
  2149.           DOS FORMAT program does this when it is run on floppy disks, but on
  2150.           hard disks the DOS program merely makes sure that all required address
  2151.           marks are present - they are created by the disk manufacturer or
  2152.           supplier's low-level format program, which may or may not be available
  2153.           to the end user. After each address mark there follows a short gap (to
  2154.           allow the controller time to recognize and respond to the address
  2155.           mark), then the CRC or ECC data, then the raw data. A sector normally
  2156.           contains 512 bytes of raw data, and DOS 4.xx requires that this be the                                                       ________                 
  2157.           case, but DOS versions prior to 4.00 (and HDTEST) can recognize and
  2158.           deal appropriately with devices with non-standard sector sizes.
  2159.  
  2160.           When a sector read/write command is passed to the disk controller, it
  2161.           (the controller) causes the disk's read/write head to move (seek) to                                                                      ____    
  2162.           the specified track, waits a few milliseconds for it to settle down,
  2163.           and then starts to "pay attention to" the data passing underneath it.
  2164.           The controller locates and reads the address marks to confirm that the
  2165.           read/write head is positioned at the correct track and to identify
  2166.           each sector. If data is being read from the disk, the raw data and
  2167.           recorded CRC or ECC from the requested sector(s) are transferred into
  2168.           the disk controller's internal buffers and (assuming that no errors
  2169.           are detected), thence to main memory. If data is being written, the
  2170.           controller derives the error-checking data from the raw data and
  2171.           writes both to the disk. Some of this process is under the direct
  2172.           control of the controller hardware, but it is supervised by the
  2173.           device's ROM BIOS, which is responsible for error-reporting. Errors
  2174.           can occur at almost any stage of the read/write process, but (if the
  2175.           disk is working at all) usually result from media defects or problems
  2176.           developing in the mechanical components of the hard disk drive. Media
  2177.           defects, once present, are generally constant in size and position
  2178.           (although jarring a disk while it is being written to may sometimes
  2179.           generate a temporary bad sector).                     _________             
  2180.  
  2181.  
  2182.                                  HDTEST DISK ERROR REPORTS                                 _________________________
  2183.  
  2184.           When HDTEST detects an error during read/write testing of a sector or
  2185.           cluster which has not previously been marked as bad, a (normally)
  2186.           four-line error message is printed, either to the screen (by default),
  2187.           
  2188.           
  2189.                                          Page 36 
  2190.            
  2191.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  2192.           
  2193.           
  2194.           to the printer (/P option), or to the logging file (if an output
  2195.           device was specified). The first line of the message simply indicates
  2196.           the sector or cluster number at which the error occurred. The second
  2197.           line indicates what sort of error was detected and during what phase
  2198.           of read/write testing it occurred. The third line indicates whether
  2199.           HDTEST was able to recover and/or remap the data from the bad sector
  2200.           or cluster, and the fourth indicates either the file which a bad
  2201.           cluster formed part of or that the cluster was not in use. If it was
  2202.           not possible to read one or more sectors from a cluster which
  2203.           contained data (unrecoverable read error), a further two-line message
  2204.           is printed which notes how many sectors were unreadable and how the                                          _______                            
  2205.           data from the bad cluster has been remapped (which depends on whether
  2206.           a /Zn option was specified on the command line). If the /M flag is not
  2207.           specified when HDTEST is run on a system that suffers from the "multi-
  2208.           track read" problems discussed in the main part of the documentation,
  2209.           multiple bad clusters may be reported with no errors persisting on                                                     __                     
  2210.           sector-by sector reading. These reports should disappear if the /M
  2211.           flag is used.
  2212.  
  2213.           If the "verbose" form of the /G option is used, the bad sector report
  2214.           will contain the equivalent of the second and third lines of the bad
  2215.           cluster report for each bad sector. Note that, if the /X option is not                         ___________________                                    
  2216.           used to prevent testing of previously flagged bad clusters, these may
  2217.           give rise to spurious warnings of possible data loss in the third line                       ________                                                 
  2218.           of the bad sector report. If no unrecoverable bad clusters were                     ______                                 ________     
  2219.           reported, such warnings can safely be ignored. If the default form of
  2220.           the /G option is used, the bad sector report gives only a Hex error
  2221.           code for each bad sector. The LSB of this code is the value returned
  2222.           (in AH) by INT 13. The MSB of the code depends on the phase of testing
  2223.           during which the error occurred. In general, if the first digit (of a
  2224.           four digit code) is C or above, an unrecoverable error occurred, but
  2225.           error codes FFFD through FFFF have special meanings and usually
  2226.           indicate recovered errors.
  2227.  
  2228.           When the program detects an error during read/write testing of a
  2229.           sector in the DOS area, only the first three lines described above are
  2230.           printed and the program aborts. The remainder of this Appendix
  2231.           contains more details of and further information on the possible
  2232.           contents of lines two and three of HDTEST's disk error message.
  2233.  
  2234.           The second line of the disk read/write error message will usually take
  2235.           the form: "[Error Type] occurred during [phase of testing]". Possible
  2236.           values for [Error Type] are as follows (in alphabetical order):
  2237.  
  2238.           Address Mark Not Found - this is a fairly common error reported for
  2239.           bad blocks which are present from "scratch" on a new disk, since a
  2240.           significant media defect may well not retain sector formatting data
  2241.           and/or the manufacturer may have made sure that a known bad track on
  2242.           the disk will not be used by deliberately not writing address marks
  2243.           there. If new bad clusters are reported with this error message, it is
  2244.           likely that the hard disk surface has been physically damaged (perhaps
  2245.  
  2246.           
  2247.           
  2248.                                          Page 37 
  2249.            
  2250.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  2251.           
  2252.           
  2253.           by a shock to the drive) but possible that the controller has a
  2254.           problem.
  2255.  
  2256.           Bad Controller - this means what it says, but check that all boards
  2257.           and cables are properly seated before giving up.
  2258.  
  2259.           Bad Sector - the BIOS was instructed to read a sector number which
  2260.           should not (according to its configuration data) exist on the device.
  2261.           This indicates either an internal program error or that the program is
  2262.           having a problem determining the physical layout of the disk. Check
  2263.           the values reported by HDCHEK against those in the disk documentation.
  2264.  
  2265.           Bad Track - analogous to "Bad Sector".
  2266.  
  2267.           Buffer Comparison - the data read from a sector differs from that
  2268.           written to it. This should not happen, since it suggests either that
  2269.           the device's error-detection functionality has failed or that it has
  2270.           been overwhelmed. If it does occur, the most likely causes are
  2271.           controller and memory problems (in that order of likelihood).
  2272.  
  2273.           Corrected ECC - as discussed at some length above, the data retrieved
  2274.           from a hard disk was incorrect but the device's error-correction
  2275.           hardware was (probably) able to correct it.
  2276.  
  2277.           DMA Boundary Violation - should not occur (HDTEST positions its
  2278.           buffers to avoid crossing segment boundaries). Suggests either an
  2279.           internal program error or a controller/BIOS problem.
  2280.  
  2281.           Hardware Timeout - a seek or other operation was not completed within
  2282.           the maximum time allowed by the BIOS. Check connections, reseat
  2283.           boards, otherwise suspect the mechanics of the disk.
  2284.  
  2285.           Init Fail - should not occur (on a working disk).
  2286.  
  2287.           Internal - internal program error. Make sure that your working copy of
  2288.           HDTEST has not been corrupted. The disk is probably not defective.                                                     ________               
  2289.  
  2290.           Invalid Command - should not occur. Treat as Internal Error.
  2291.  
  2292.           Multiple Errors - one or more additional errors occurred while HDTEST
  2293.           was attempting to recover from an initial one. Multiple phase report
  2294.           lines will be printed but the error types cannot be further specified.
  2295.  
  2296.           Recovered - HDTEST recovered from the error and did not report on the
  2297.           error type (should not occur).
  2298.  
  2299.           Reset Fail - The device could not be reset (after an error). Usually
  2300.           indicates major problems with the disk or controller, but check
  2301.           connections, etc.
  2302.  
  2303.           Sector Not Found - the requested sector's address mark was not found.
  2304.           Likely to result from a media defect.
  2305.           
  2306.           
  2307.                                          Page 38 
  2308.            
  2309.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  2310.           
  2311.           
  2312.           Seek Fail - after a seek to a track, the controller found that the
  2313.           read/write head was not positioned correctly. Usually indicates a
  2314.           significant problem with the (drive) hardware.
  2315.  
  2316.           Sense Fail - the controller cannot find the drive! Check connections,
  2317.           etc.
  2318.  
  2319.           Uncorrected ECC - data error too major to be corrected. Usually a
  2320.           media defect. This message will also be produced if a CRC error is
  2321.           detected on a floppy disk.
  2322.  
  2323.           Undefined - the BIOS cannot figure out what went wrong, but something
  2324.           did!
  2325.  
  2326.           Unknown - likewise!
  2327.  
  2328.           Write Protection - HDTEST is attempting to write to a write-protected
  2329.           device.
  2330.  
  2331.  
  2332.           Possible forms for the rest of the second line are as follows:
  2333.  
  2334.           ... Error (unrecovered) occurred during first read - the cluster could
  2335.           not be read without error in five tries before a seek to the other
  2336.           "end" of the disk.
  2337.  
  2338.           ... Error occurred during first read - the error occurred during the
  2339.           first read but was recovered after one or more retries.
  2340.  
  2341.           ... Error occurred during read after seek - the error occurred when
  2342.           the cluster was read after a seek away.
  2343.  
  2344.           ... Error occurred during pattern read/writes - the error occurred
  2345.           during the pattern read/write phase of testing.
  2346.  
  2347.           ... Error occurred during final write - the error occurred when the
  2348.           saved copy of the cluster was being restored to the disk.
  2349.  
  2350.           ... Error occurred during read after final write - the error occurred
  2351.           when the restored cluster was being read back.
  2352.  
  2353.           ... (Buffer comparison) error occurred after final read - the copy of
  2354.           the cluster read back after restoration to the disk differed from its
  2355.           original memory image.
  2356.  
  2357.  
  2358.           There are only three basic forms of the third line:
  2359.  
  2360.           This error is (or "These errors are") recoverable (no data loss has
  2361.           occurred). - the bad cluster was read successfully and has been
  2362.           successfully restored to its original form, but it remains suspect and
  2363.           will (with your permission) be remapped.
  2364.           
  2365.           
  2366.                                          Page 39 
  2367.            
  2368.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  2369.           
  2370.           
  2371.           This error is unrecoverable, but remapping is possible. - the bad
  2372.           cluster was read successfully but has not been restored to its                                                ___                     
  2373.           original form. Remapping should be successful, but the data will be
  2374.           lost if this is not permitted.
  2375.  
  2376.           This error is unrecoverable, and data may be lost! - the bad cluster
  2377.           was not read successfully and will be remapped as provided by the
  2378.           value of the /Z switch parameter if remapping is permitted. In any
  2379.           event, some data loss has almost certainly occurred.
  2380.  
  2381.  
  2382.  
  2383.  
  2384.  
  2385.  
  2386.  
  2387.  
  2388.  
  2389.  
  2390.  
  2391.  
  2392.  
  2393.  
  2394.  
  2395.  
  2396.  
  2397.  
  2398.  
  2399.  
  2400.  
  2401.  
  2402.  
  2403.  
  2404.  
  2405.  
  2406.  
  2407.  
  2408.  
  2409.  
  2410.  
  2411.  
  2412.  
  2413.  
  2414.  
  2415.  
  2416.  
  2417.  
  2418.  
  2419.  
  2420.  
  2421.  
  2422.  
  2423.           
  2424.           
  2425.                                          Page 40 
  2426.                 
  2427.                Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher               ________________________________       _______________________________
  2428.                
  2429.                
  2430.  
  2431.                    APPENDIX C - EXAMPLE PROGRAM RUNS                   _________________________________
  2432.  
  2433.      Screen display from successful run of HDCHEK on partition occupying the
  2434.      whole of a 20 Mb hard disk:
  2435.  
  2436. Device C: appears to be the DOS partition of a hard disk
  2437. It contains 41531 sectors
  2438. It starts at absolute sector 17 on the disk      {THIS IS CORRECT}                                                  _______________ 
  2439. The total partition size is approximately 20 Mb
  2440. There are 4 heads and 17 sectors/track
  2441. Sector size is 512 bytes
  2442. Each of the 2 (16 bit) FATs occupies 41 sectors
  2443. The Root Directory occupies 32 sectors
  2444. The data area starts at DOS sector 115, and contains 10354 clusters, each
  2445. consisting of 4 sectors
  2446. The directory scan was successful; a total of 1260 files and subdirectories
  2447. was found.
  2448.  
  2449.      Screen display from successful run of HDCHEK on a freshly FORMATted DSDD
  2450.      9-sector floppy disk:
  2451.  
  2452. Device A: is not a hard disk - using DOS interrupts
  2453.  
  2454. Device A: is a floppy disk
  2455. The disk contains 720 sectors
  2456. There are 2 heads and 9 sectors/track
  2457. Sector size is 512 bytes
  2458. Each of the 2 (12 bit) FATs occupies 2 sectors
  2459. The Root Directory occupies 7 sectors
  2460. The data area starts at DOS sector 12, and contains 354 clusters, each
  2461. consisting of 2 sectors
  2462. The directory scan was successful; a total of 0 files and subdirectories
  2463. was found.
  2464.  
  2465.      Screen display from run of HDCHEK on 20 Mb DOS partition - directory
  2466.      structure bad or unrecognizable:
  2467.  
  2468. Device C: appears to be the DOS partition of a hard disk
  2469. It contains 41531 sectors
  2470. It starts at absolute sector 17 on the disk
  2471. The total partition size is approximately 20 Mb
  2472. There are 4 heads and 17 sectors/track
  2473. Sector size is 512 bytes
  2474. Each of the 2 (16 bit) FATs occupies 41 sectors
  2475. The Root Directory occupies 32 sectors
  2476. The data area starts at DOS sector 115, and contains 10354 clusters, each
  2477. consisting of 4 sectors
  2478. The preliminary directory scan failed.
  2479.  
  2480.  
  2481.  
  2482.                
  2483.                
  2484.                                               Page 41 
  2485.                 
  2486.                Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher               ________________________________       _______________________________
  2487.                
  2488.                
  2489.      Screen display from run of HDCHEK on 20 Mb DOS partition - FATs not
  2490.      identical:
  2491.  
  2492. FATS are different
  2493. FAT discrepancy at byte 20F - FAT 1 has FF; FAT 2 has F8
  2494. Continue comparison (Y/N)? [Y]: n     {user input}                                _                 
  2495.  
  2496. Device C: appears to be the DOS partition of a hard disk
  2497. It contains 41531 sectors
  2498. It starts at absolute sector 17 on the disk
  2499. The total partition size is approximately 20 Mb
  2500. There are 4 heads and 17 sectors/track
  2501. Sector size is 512 bytes
  2502. Each of the 2 (16 bit) FATs occupies 41 sectors
  2503. The Root Directory occupies 32 sectors
  2504. The data area starts at DOS sector 115, and contains 10354 clusters, each
  2505. consisting of 4 sectors
  2506.  
  2507.  
  2508.  
  2509.      Screen display from run of HDCHEK - program unable to deduce disk
  2510.      structure - disk not recognizable as a DOS device:
  2511.  
  2512. Unrecognized media descriptor byte! - see error code
  2513. Error Code = F1      {F1 is not a media descriptor byte used by DOS}
  2514.  
  2515.  
  2516.  
  2517.  
  2518.  
  2519.  
  2520.  
  2521.  
  2522.  
  2523.  
  2524.  
  2525.  
  2526.  
  2527.  
  2528.  
  2529.  
  2530.  
  2531.  
  2532.  
  2533.  
  2534.  
  2535.  
  2536.  
  2537.  
  2538.  
  2539.  
  2540.  
  2541.                
  2542.                
  2543.                                               Page 42 
  2544.            
  2545.           Documentation for HDTEST V5.35a         Copyright 1991, P. R. Fletcher          ________________________________       _______________________________
  2546.           
  2547.           
  2548.      Log file from successful run of HDTEST on 20 Mb DOS partition:
  2549.  
  2550.      HDTEST Log File - Wed Jan 07 11:44:52 1986
  2551.      Testing Device C:
  2552.  
  2553.      No new bad clusters identified - HDTEST finished.
  2554.      Wed Jan 07 16:10:41 1987
  2555.  
  2556.  
  2557.      Log file from run of HDTEST on 20 Mb DOS partition - one bad cluster
  2558.      detected and remapped:
  2559.  
  2560.      HDTEST Log File - Mon Jan 05 21:09:32 1987
  2561.      Testing Device C:
  2562.  
  2563.      Read/Write error at cluster number 7623!!
  2564.      Corrected ECC error occurred during pattern read/writes
  2565.      This error is recoverable (no data loss has occurred).
  2566.      Bad cluster is in file \MYFILES\DATA5\FFT1234.DAT
  2567.  
  2568.      1 new bad clusters identified, marked, and remapped - HDTEST finished.
  2569.      Tue Jan 06 05:08:04 1987
  2570.  
  2571.  
  2572.  
  2573.  
  2574.  
  2575.  
  2576.  
  2577.  
  2578.  
  2579.  
  2580.  
  2581.  
  2582.  
  2583.  
  2584.  
  2585.  
  2586.  
  2587.  
  2588.  
  2589.  
  2590.  
  2591.  
  2592.  
  2593.  
  2594.  
  2595.  
  2596.  
  2597.  
  2598.  
  2599.  
  2600.           
  2601.           
  2602.                                          Page 43 
  2603.  
  2604.                         REGISTRATION FORM - HDTEST V5.35                        ________________________________
  2605.  
  2606.      Please complete this form and return it with a check or money order for
  2607.      $35.00 (+ $5.00 for shipping outside North America) or equivalent to:
  2608.  
  2609.                      Computer Counselors, Inc.
  2610.                      1515 West Montgomery Avenue
  2611.                      Rosemont
  2612.                      PA 19010
  2613.                      U.S.A.
  2614.  
  2615.      None of the information on this form will be passed on to any other
  2616.      individual or commercial organization. Pennsylvania residents must pay
  2617.      Sales Tax (currently 6%) on all orders.
  2618.  
  2619.      --------------------------------------------------------------------------
  2620.  
  2621.      This information is required to process your Registration:
  2622.  
  2623.      Last Name:____________________________  Other Names:______________________
  2624.  
  2625.      Address:______________________________  Town/City:________________________
  2626.  
  2627.      State:_____________  Post Code:____________  Telephone:_________________
  2628.                                                            (evenings/weekends)
  2629.  
  2630.      I understand that this software is supplied without warranty, express or
  2631.      implied, and agree not to hold its author liable for any direct or
  2632.      consequential loss arising out of my use of it.
  2633.  
  2634.      Signature:______________________________
  2635.  
  2636.      -------------------------------------------------------------------------
  2637.  
  2638.      You are requested, but not required, also to answer the following
  2639.      questions:
  2640.  
  2641.      On What type(s) of computer are you using HDTEST? _________________________
  2642.  
  2643.      CPU (8088, 8086, etc.)? __________   Amount of RAM (kB)? ____________
  2644.  
  2645.      Type & Size of Hard Disk(s)? ____________________________________
  2646.  
  2647.      Make and Type of Hard Disk Controller(s)? ______________________________
  2648.  
  2649.      Do you own a Modem?                                             Y  N
  2650.  
  2651.      Are you a member of BIX?   Y  N        Compuserve?              Y  N
  2652.  
  2653.      How did you obtain/hear about this program?
  2654.  
  2655.      Did you think that the $35.00 registration fee for this program was:
  2656.  
  2657.      Very Good Value?              About Right?             Excessively High?
  2658.  
  2659.  
  2660.      Are there any other utility programs that you would like to see made
  2661.      available as "User Supported Software"? What sort of programs?
  2662.